agilescientific / striplog

Lithology and stratigraphic logs for wells or outcrop.
https://code.agilescientific.com/striplog
Apache License 2.0
204 stars 69 forks source link

Read DataFrames, Striplog.from_df() #160

Open DougiB opened 2 years ago

DougiB commented 2 years ago

As I am loading large project information with various locations from a single Excel file, I am using pandas to filter my information and per location. This allows me to speed up my looping through the data. However, if I then want to create a striplog I have to create and save temporary CSV file for that location, reload it and then do strip = Striplog.from_cvs().

Would it be possible to allow Striplog to read DataFrames? I thought it could be something like the following: df_geology = pd.read_excel() strip = Striplog.from_df(df_geology, base = "col1", top = "col2", comp_formation = "col3", description = "col4")