Git Product home page Git Product logo

Comments (6)

Chrismarsh avatar Chrismarsh commented on August 30, 2024

Units in the variable name?

from chm.

NicWayand avatar NicWayand commented on August 30, 2024

I was thinking as separate header lines like:

variable1, variable2, variablen
unit1, unit2, unitn
avg1, sample2, avgn,
data, data, data,
data, data, data

from chm.

Chrismarsh avatar Chrismarsh commented on August 30, 2024

Gross to post process though?

from chm.

NicWayand avatar NicWayand commented on August 30, 2024

Depends on your definition of gross :). I think it is easy to import in pandas. I do this for the station files here that follow that format.

# Ascii data format info
c_header = 4 # Header lines
c_column_line = 1 # line where column names start
c_delimiter = ','

# Import data to pandas dataframe
dat = ascii.read(cfile,header_start=c_column_line,data_start=c_header,delimiter=c_delimiter)
datain = pd.DataFrame(dat.as_array())

# Import header info
headerinfo = pd.read_csv(cfile,nrows=2,skiprows=1)

Having received many data sets without units/metadata in the past, I am a big proponent of including metadata. Going to a hierarchical data format like netcdf might be easier to include this extra meta data.

from chm.

Chrismarsh avatar Chrismarsh commented on August 30, 2024

I've had some which have almost unparsable headers due to a mix of '_', ' ', etc. As long as the format is well defined, I have no problem doing this.

I've always wanted the models to declare their outputs in a manner that enforced units between models. In fact, I've actually had bugs where I messed up the units. Something like this
http://www.boost.org/doc/libs/1_61_0/doc/html/boost_units/Examples.html

would be ideal, I think.

from chm.

Chrismarsh avatar Chrismarsh commented on August 30, 2024

Closing to split into two issues

from chm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.