This is documentation for an old release of NumPy (version 1.6.0). Read this page in the documentation of the latest stable release (version > 1.17).
Return an array laid out in Fortran order in memory.
Parameters : | a : array_like
dtype : str or dtype object, optional
|
---|---|
Returns : | out : ndarray
|
See also
Examples
>>> x = np.arange(6).reshape(2,3)
>>> y = np.asfortranarray(x)
>>> x.flags['F_CONTIGUOUS']
False
>>> y.flags['F_CONTIGUOUS']
True