Skip to content

Contour Time Series data and output all to one shapefile for upload to kepler.gl

Notifications You must be signed in to change notification settings

metostom/contouring

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Contouring

Contouring flat-file time-series Pressure Transducer data and conversion to a web uploadable format for visualization in Kepler.gl

Surface Creation options include:

  • Interpolation
    • cubic spline (default)
    • linear
  • Triangulation subdivision
  • Gaussian Process Regression (Kriging)
    • (RBF + Constant Kernels)

Uses

Python

  • Pandas
  • Geopandas
  • Shapely
  • Numpy
  • Matplotlib
  • Scipy
  • Scikit-learn

Usage

Input Data File

Accepts Excel flat file format where one row corresponds to one groundwater elevation at one DateTime of the form:

Location DateTime X Y Z
MW-1 2020-12-03 9:00 123453 435679 17.5
... ... ... ... ...

Code Sample

from Contour import ContourData

cd = ContourData(
        filepath = 'WellElevationSubsetSmaller.xlsx',
        xcol = 'X',
        ycol = 'Y',
        zcol = "Water Elevation(ft NAVD88)",
        tcol = "DateTimeRounded",
        crs = 3456,
        method = 'linear',
        steps = 50
)

cd.subsetData()
cd.contourData(subdivisions=5)
cd.extractGeometry()
cd.mergeGeometry()
cd.reproject()
cd.toGeoJSON("test.json")

Efficiency

Interpolation methods increase run time significantly. If interpolating, set interpolation "steps" to largest possible size and triangulation subdivisions to lower values for fastest run time. Often larger step sizes provide a smoother contour line with an appropriate amount of subdivisions.

Triangulation subdivision will run fastest, however spatially sparse data may provide undesirable results.

Output File Size

File size will increase drastically with increased number of subdivisions and will increase with smaller step sizes.

Output Looks like

Alt Text

Animated In Kepler.gl

Alt Text

About

Contour Time Series data and output all to one shapefile for upload to kepler.gl

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages