Code Monkey home page Code Monkey logo

calkulate's Introduction

Hi there ๐Ÿ‘‹

I am a marine carbonate chemist at NIOZ Royal Netherlands Institute for Sea Research, Texel.

calkulate's People

Contributors

codacy-badger avatar mphtest avatar mvdh7 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

calkulate's Issues

No alkalinity results in output file

I'm having trouble figuring out how to export the results of calkulate. I tried using the following commands:

result = data.solve()
result.to_csv("result.csv")

And got the following results (see "results.csv"). It didn't actually calculate alkalinity for some reason.

I tried modifying my code to generate the data in an output file (see code below):

**#!/usr/bin/env python

import numpy as np
import os
import pandas as pd
import calkulate as calk

data = calk.read_csv("/home/sheikc/bjkramer/AlkalinityFiles/2022Metadata+Standards.csv").calkulate()
data.alkalinity # <== here are your alkalinity results
data.alkalinity.to_csv("/home/sheikc/bjkramer/AlkalinityFiles/GreatLakes2022Alkalinity_Calkulate.csv", index=False)**

And I just got an empty dataframe aside from the header name ("GreatLakes2022Alkalinity_Calkulate.csv").

I also keep getting the error that calkulate cannot find the standard files. I tried moving them to another directory separate from the titration files (see filepath in "2022Metadata+Standards.csv") thinking this would fix the issue and it didn't.

Could this be why I'm not getting results?

Whatever the issue is, I get the feeling it's a quick fix, but I'm not sure.

2022Metadata+Standards.csv
GreatLakes2022Alkalinity_Calkulate.csv
result.csv

Problmes with executing examples

Dear Matthew,

here there is one error message I will get with a couple of installations of Python 3.8 or 3.7:
I have installed your PyCO2SYS ver 1.5.1 and your calkulate ver. 2.3.0.
When I want to import calkulate following message occurs:
cannot import name 'assemble' from 'PyCO2SYS' (path) init.py

Unfortunately the package 'calkulate' is not running.
Do you have any clue about this? Thanks a lot.
best regards
Matthias

Allow CT to vary throughout the titration

Enable the solve functions to allow the dissolved inorganic carbon (CT) concentration to vary through the titration, for example to represent CO2 loss from the sample.

pH and "measurement_type"

To the best of my knowledge, Calkulate does not currently have the capacity to process titrations with an EMF reading in pH units. The metadata table at tests/data/titration_table.csv denotes a column called "measurement_type" with options of "EMF" and "pH", but I do not believe the program currently utilizes this option. Replacement of mV readings with the corresponding pH values (calculated with the estimated value of emf0 for the titration) results in an error: "Calkulate: ERROR solving '[sample]'!".

[(https://calkulate.readthedocs.io/en/latest/io)/] calls for EMF readings in either mV or pH, but this may be misleading. Might it be useful to either implement support for pH-based titration, or remove references to the same? Support for pH-based titration could be implemented by conversion (i.e. convert/pH_to_emf) with a user-provided value of emf0.

No results

Dear Dr. Matthew Humphrey,
thanks for the new versio of calkulate!
when I go for the metadatafile I get following output:

Calkulate: calibrating titrant_molinity...

Calkulate: ERROR calibrating 'seawater-CRM-144.dat'!
Calkulate: ERROR calibrating 'filename-does-not-exist.dat'!
Calkulate: ERROR calibrating 'seawater-CRM-144-function.dat'!
Calkulate: ERROR calibrating 'Dickson-1981-pH-no_phosphate.dat'!
Calkulate: ERROR calibrating 'Dickson-1981-pH-with_phosphate.dat'!
Calkulate: calibration complete!
Calkulate: solving alkalinity...
Calkulate: ERROR solving 'seawater-CRM-144.dat'!
Calkulate: ERROR solving 'filename-does-not-exist.dat'!
Calkulate: ERROR solving 'seawater-CRM-144-function.dat'!
Calkulate: solving complete!

The data.alkalinity values are NaN

I don't have any idea what is wrong, because I am dealing with the original titration_table.csv as meatadatafile and all *.dat files are available.
best regards
Matthias

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.