-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
wontfixThis will not be worked onThis will not be worked on
Description
Right now the times parameter has to be a pd.DatetimeIndex. While a single timestamp can be passed, this is kinda awkward as you would normally just pass a timestamp as ``pd.Timestamp`.
The function _pandas_to_utc could be modified to allow for a single time stamp being passed to the solar position algorithms. Is this a desirable feature?
The functionality would look like this:
solposx.solposition.michalsky(
times=pd.Timestamp('2020-01-01 00:00+00'),
latitude=50,
longitude=10)alternatively maybe even with a single timestamp in the form of a string:
solposx.solposition.michalsky(
times='2020-01-01 00:00+00',
latitude=50,
longitude=10)This could be achieved with addition of the following line to the _pandas_to_utc function:
if isinstance(pd_object, (str, pd.Timestamp)):
pd_object = pd.DatetimeIndex[pd_object]Metadata
Metadata
Assignees
Labels
wontfixThis will not be worked onThis will not be worked on