Skip to content

Commit 103724b

Browse files
pkdashthodson-usgsehinman
authored
[#157] Example notebook for NLDI data access (#158)
* [#157] new notebook with examples for retrieving data from NLDI * [#157] fixing corrupted notebook * [#157] deleting empty cell * [#157] adding examples with no multi-index * [#157] reformating code cells * [#157] updates to nldi examples notebook by Jeff Horsburgh * Update demos/hydroshare/USGS_dataretrieval_NLDI_Examples.ipynb Co-authored-by: Elise Hinman <[email protected]> * Update demos/hydroshare/USGS_dataretrieval_NLDI_Examples.ipynb Co-authored-by: Elise Hinman <[email protected]> * Update demos/hydroshare/USGS_dataretrieval_NLDI_Examples.ipynb Co-authored-by: Elise Hinman <[email protected]> --------- Co-authored-by: Timothy Hodson <[email protected]> Co-authored-by: Elise Hinman <[email protected]>
1 parent baa65e5 commit 103724b

9 files changed

+727
-17
lines changed

demos/hydroshare/USGS_dataretrieval_DailyValues_Examples.ipynb

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,23 @@
286286
"display(dailyMultiSites[0])"
287287
]
288288
},
289+
{
290+
"metadata": {},
291+
"cell_type": "markdown",
292+
"source": "The following example is the same as the previous example but with multi index turned off (multi_index=False)"
293+
},
294+
{
295+
"metadata": {},
296+
"cell_type": "code",
297+
"outputs": [],
298+
"execution_count": null,
299+
"source": [
300+
"dailyMultiSites = nwis.get_dv(sites=[\"01491000\", \"01645000\"], parameterCd=[\"00010\", \"00060\"],\n",
301+
" start=\"2012-01-01\", end=\"2012-06-30\", statCd=[\"00001\",\"00003\"],\n",
302+
" multi_index=False)\n",
303+
"display(dailyMultiSites[0])"
304+
]
305+
},
289306
{
290307
"cell_type": "markdown",
291308
"metadata": {},
@@ -330,4 +347,4 @@
330347
},
331348
"nbformat": 4,
332349
"nbformat_minor": 1
333-
}
350+
}

demos/hydroshare/USGS_dataretrieval_GroundwaterLevels_Examples.ipynb

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,23 @@
286286
"display(data2[0])"
287287
]
288288
},
289+
{
290+
"metadata": {},
291+
"cell_type": "markdown",
292+
"source": "The following example is the same as the previous example but with multi index turned off (multi_index=False)"
293+
},
294+
{
295+
"metadata": {},
296+
"cell_type": "code",
297+
"outputs": [],
298+
"execution_count": null,
299+
"source": [
300+
"site_ids = [\"434400121275801\", \"375907091432201\"]\n",
301+
"data2 = nwis.get_gwlevels(sites=site_ids, multi_index=False)\n",
302+
"print(\"Retrieved \" + str(len(data2[0])) + \" data values.\")\n",
303+
"display(data2[0])"
304+
]
305+
},
289306
{
290307
"cell_type": "markdown",
291308
"metadata": {

0 commit comments

Comments
 (0)