The Snake River Valley AVA Climate Explorer is an R Shiny application to interactively explore 30 years of climate data in the Snake River Valley AVA. It features tools to explore data generated by the Weather and Research Forecasting Model for water years 1988-2017.
Head Developer - Charlie Becker ([email protected]; [email protected])
Developer - Kendra Kaiser ([email protected])
Developer - Elizabeth Padian ([email protected])
Primary PI - Lejo Flores ([email protected])
This tool is currently hosted by Boise State University. Those with permissions can access the server using their Boise State login credentials via ssh. Login procedure would look like:
Directory stucture:
opt/
├── chef/
└── shiny-server/
├── bwc/
│ ├── welcome.html
│ └── hello/
│ ├── server.R
│ └── ui.R
│ └── climate-viewer
│ ├── app.R
│ ├── busyIndicator.R
│ ├── buttonIndicator.R
│ └── data/
│ └── ...
│ └── www/
│ └── ...
└── [other labs applications...]
cd /opt/shiny-server/bwc/climate-viewer
will take you directly to the application directory.
Note: The public domain address will be bwc.boisestate.edu/{nameofdirectorywithapplication}
In this case, the directory is named /climate-viewer
which would have a full domain address of bwc.boisestate.edu/climate-explorer and will change if the directory is renamed. Additionally, other Shiny apps can be created and hosted in other directories located in /opt/shiny-server/bwc/
This repository mimics the structure within the ./climate-viewer
directory, however, the data is far too large to host on github and is not present.
-
An additional example application 'hello' has been setup as an example of the ease to host various applications if needed/wanted. Each directory here is an open port and can be viewed by directory name (http://bwc.boisestate.edu/hello)
-
Shiny applications can be setup two distinct ways - everything included in an app.R file (climate-viewer) or split between ui.R and server.R files (hello). Either is fine, however, the names of them MUST be app.R or ui.R/server.R
-
busyIndicator.R and buttonIndicator.R are supplimental scripts used to display an animation after the 'create map' button is pressed on the explore page to signal to the user that the app is processing the request.
-
the
www/
folder contains various style elements (such as a .css file) and all graphics/logos/videos to be used on the site. Shiny directly looks for a /www folder, thus this folder cannot be renamed.
A brief overview of the types of data files:
File Name | Description |
---|---|
SR_AVA_simplified_pointRemove50m.json |
GeoJSON boundary of the Snake River AVA |
Yearly_Anomalies_d02.nc |
Difference between mean and annual mean - domain 02 |
AVA_Yearly_Anomalies_d02.nc |
Difference between mean and annual mean - masked by AVA |
<month>_Anomalies_d02.nc |
Difference between monthly 30YR mean and selected month of each year |
<month>_AVA_Anomalies_d02.nc |
Difference between monthly 30YR mean and selected month of each year - masked by AVA |
d01_30YR_NoLeap917.csv |
Daily aggregated values (Domain 01) for all 30 years (not including september 2017) |
d02_30YR_NoLeap917.csv |
Daily aggregated values (Domain 02) for all 30 years (not including september 2017) |
AVA_30YR_NoLeap917.csv |
Daily aggregated values (Domain 02 - AVA) for all 30 years (not including september 2017) |
SS_30YR_NoLeap917.csv |
Daily aggregated values (Point within Sunny Slope) for all 30 years (not including september 2017) |
WY<year>_yearly_stats_d02.nc |
Daily values (Domain 02) |
AVA_WY<year>_yearly_stats_d02.nc |
Daily values (Domain 02 - AVA) |
AVA_30YR_df_all_vars.csv |
Annual values for each grid point within the AVA |
If you choose to develop and test on an IDE such as Rstudio on your local machine, here's the recommended procedure:
-
Make sure you have these libraries installed on your local machine:
- Git
- netcdf
- GDAL
-
Clone the github repository via
git clone https://github.com/LEAF-BoiseState/DOA_web_viewer
-
Copy a portion of data to your local machine (you don't need all of it) with secure copy:
-
Recommended files to copy to provide most functionality (total ~1.75 GB):
SR_AVA_simplified_pointRemove50m.json
(1.3 MB) - (don't need to copy, should be provided in the data directory when cloned)Yearly_Anomalies_d02.nc
(108 MB)Apr_Anomalies_d02.nc
(108 MB)d02_30YR_NoLeap917.csv
(1.2 MB)AVA_WY1988_yearly_stats_d02.nc
(1.3 GB)AVA_30YR_df_all_vars.csv
(155 MB)
-
scp <username>@bwc.boisestate.edu://opt/shiny-server/bwc/climate-viewer/data/Yearly_Anomalies_d02.nc <path>/DOA_web_viewer/data/
is an example of how to copy data from the server to your machine.
-
-
Once you have the data copied into the data directory of the cloned repository, open
app.R
and change line 22 to the path where you cloned the repository. -
Run the application - it should pop up immeadiately in your local browser.