By default, the dtype of the returned array will be the common NumPy dtype of all types in the DataFrame. For example, if the dtypes are float16 and float32, the results dtype will be float32. This may require copying data and coercing values, which may be expensive.
Parameters:
dtype: str or numpy.dtype, optional
The dtype to pass to numpy.asarray().
copy: bool, default False
Whether to ensure that the returned value is not a view on another array. Note that copy=False does not ensure that to_numpy() is no-copy. Rather, copy=True ensure that a copy is made, even if not strictly necessary.
na_value: Any, optional
The value to use for missing values. The default value depends on dtype and the dtypes of the DataFrame columns.
Returns:
numpy.ndarray
The NumPy array representing the values in the DataFrame.