Skip to content

Commit 1177146

Browse files
committed
removing func for ioos regional data
1 parent ea2e855 commit 1177146

1 file changed

Lines changed: 0 additions & 62 deletions

File tree

website/create_gts_regional_landing_page.py

Lines changed: 0 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -91,68 +91,6 @@ def stacked_bar_plot(totals):
9191

9292
return fig1, fig2
9393

94-
def get_ioos_regional_data():
95-
e = ERDDAP(
96-
server="https://erddap.ioos.us/erddap",
97-
protocol="tabledap",
98-
)
99-
100-
e.response = "csv"
101-
e.dataset_id = "gts_regional_statistics"
102-
103-
df = e.to_pandas(
104-
index_col="time (UTC)",
105-
parse_dates=True
106-
)
107-
return df
108-
109-
def get_ioos_regional_yearly_stats():
110-
111-
df = get_ioos_regional_data()
112-
113-
groups = df.groupby([pd.Grouper(
114-
freq="YE",
115-
),'region'])
116-
117-
totals = groups[
118-
["met", "wave"]
119-
].sum() # reducing the columns so the summary is digestable
120-
121-
#totals = s.assign(total=s["met"] + s["wave"])
122-
totals.index = totals.reset_index().set_index('time (UTC)').index.to_period('Y')
123-
124-
# Not returning summarized table by year and RA...
125-
126-
return totals
127-
128-
def get_ioos_regional_stats():
129-
130-
e = ERDDAP(
131-
server="https://erddap.ioos.us/erddap",
132-
protocol="tabledap",
133-
)
134-
135-
e.response = "csv"
136-
e.dataset_id = "gts_regional_statistics"
137-
138-
df = e.to_pandas(
139-
index_col="time (UTC)",
140-
parse_dates=True
141-
)
142-
143-
groups = df.groupby(pd.Grouper(
144-
freq="ME",
145-
))
146-
147-
s = groups[
148-
["met", "wave"]
149-
].sum() # reducing the columns so the summary is digestable
150-
151-
totals = s.assign(total=s["met"] + s["wave"])
152-
totals.index = totals.index.to_period("M")
153-
154-
return totals, e
155-
15694
def get_ndbc_full_stats():
15795

15896
e = ERDDAP(

0 commit comments

Comments
 (0)