windkit.io.wasp.format_tab#
- windkit.io.wasp.format_tab(wsfreq, wdfreq, wsbins, coords, metadata=None)[source]#
Format tab data as a .tab file content string.
Accepts normalized (0-1) frequency values and converts them to per-mille (wsfreq) and percent (wdfreq) for the file format.
- Parameters:
wsfreq (ndarray(n_wsbins, n_sectors)) – Wind speed frequencies, normalized 0-1.
wdfreq (ndarray(n_sectors)) – Wind direction frequencies, normalized 0-1.
wsbins (ndarray(n_wsbins+1)) – Wind speed bin edges (first element should be 0).
coords (dict) – Dictionary with “south_north”, “west_east”, “height”.
metadata (dict, optional) – Dictionary with “description”. Defaults to {“description”: “No Header”}.
- Returns:
The formatted .tab file content.
- Return type: