8000 Create `pvlib.iotools.get_solrad` by kandersolar · Pull Request #1967 · pvlib/pvlib-python · GitHub
[go: up one dir, main page]

Skip to content

Create pvlib.iotools.get_solrad #1967

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 17 commits into from
Mar 5, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
don't use "inclusive" with pd.date_range
it is only available from pandas v1.4 onwards, so can't use it in pvlib yet
  • Loading branch information
kandersolar committed Feb 9, 2024
commit 159532d4ec6883bd08a6d724a3f2595b2ea6491b
2 changes: 1 addition & 1 deletion pvlib/iotools/solrad.py
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ def get_solrad(station, start, end,
end = pd.to_datetime(end)

# Generate list of filenames
dates = pd.date_range(start, end, freq='d', inclusive='both')
dates = pd.date_range(start.floor('d'), end, freq='d')
filenames = [
f"{station}/{d.year}/{station}{d.strftime('%y')}{d.dayofyear:03}.dat"
for d in dates
Expand Down
0