예제 #1
0
def test_dashboard_with_invalid_datatype():
    with pytest.raises(ValueError):
        Dashboard(str)
예제 #2
0
def dash_for_Array(data):
    return Dashboard(data.temp)
예제 #3
0
#one_image_res = dsi.isel(time=[0]).to_array().values

#plot first image

dsi.isel(time=[0]).to_array().plot()  #shows upsidedown than imshow

# <codecell>
# or, select by date/name
dsi.sel(time='05/31/1969-00').to_array().plot()

# <codecell>
#dsi.to_netcdf('dtw_historic_with_dates.nc')
dsi.to_netcdf('dtw_historic_with_dates_netcdf3.nc', format='NETCDF3_64BIT')
# <codecell>

dashboard = Dashboard(ds_wt)
dashboard.show()
#
#%% select points to plot tiime variation and probability distribution

one_location = ds_wt.isel(x=[600], y=[500]).to_array()

#plot one_location

#ds_wt.isel(x=[500], y = [500]).to_array().plot() #shows upsidedown than imshow

# <codecell> how to define an xrray dataset

sns.distplot(one_location)

sns.distplot(one_location, bins=20, kde=False, rug=True)
예제 #4
0
def dashboard(data):
    return Dashboard(data)
예제 #5
0
import xarray as xr
import xrviz
from xrviz.dashboard import Dashboard

ds = xrviz.sample_data.great_lakes

dash = Dashboard(ds)
dash.show()