[CHNOSZ-commits] r429 - in pkg/CHNOSZ: . demo inst man vignettes
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Fri Apr 5 06:31:54 CEST 2019
Author: jedick
Date: 2019-04-05 06:31:52 +0200 (Fri, 05 Apr 2019)
New Revision: 429
Modified:
pkg/CHNOSZ/DESCRIPTION
pkg/CHNOSZ/demo/adenine.R
pkg/CHNOSZ/inst/CHECKLIST
pkg/CHNOSZ/man/eqdata.Rd
pkg/CHNOSZ/vignettes/anintro.Rmd
pkg/CHNOSZ/vignettes/mklinks.sh
Log:
anintro.Rmd: improve description of reset()
Modified: pkg/CHNOSZ/DESCRIPTION
===================================================================
--- pkg/CHNOSZ/DESCRIPTION 2019-03-09 00:43:47 UTC (rev 428)
+++ pkg/CHNOSZ/DESCRIPTION 2019-04-05 04:31:52 UTC (rev 429)
@@ -1,6 +1,6 @@
-Date: 2019-03-09
+Date: 2019-04-05
Package: CHNOSZ
-Version: 1.3.1-9
+Version: 1.3.1-10
Title: Thermodynamic Calculations and Diagrams for Geochemistry
Authors at R: c(
person("Jeffrey", "Dick", , "j3ffdick at gmail.com", role = c("aut", "cre"),
Modified: pkg/CHNOSZ/demo/adenine.R
===================================================================
--- pkg/CHNOSZ/demo/adenine.R 2019-03-09 00:43:47 UTC (rev 428)
+++ pkg/CHNOSZ/demo/adenine.R 2019-04-05 04:31:52 UTC (rev 429)
@@ -3,7 +3,7 @@
# notable functions in this demo:
# EOSregress() - to regress HKF coefficients from Cp data
-# add.obigt() - to add thermodynamic data that are not in the default database
+# mod.obigt() - to modify the thermodynamic database for comparisons with an older set of parameters for adenine
# LCT17 = Lowe et al., 2017 (J. Chem. Thermodyn., doi:10.1016/j.jct.2017.04.005)
# LH06 = LaRowe and Helgeson, 2006 (Geochim. Cosmochim. Acta, doi:10.1016/j.gca.2006.04.010)
Modified: pkg/CHNOSZ/inst/CHECKLIST
===================================================================
--- pkg/CHNOSZ/inst/CHECKLIST 2019-03-09 00:43:47 UTC (rev 428)
+++ pkg/CHNOSZ/inst/CHECKLIST 2019-04-05 04:31:52 UTC (rev 429)
@@ -21,7 +21,7 @@
- run R CMD check using R compiled without long doubles (emulating Solaris checks on CRAN)
(CFLAGS=-ffloat-store ./configure --disable-long-double)
-- size reduction of vignettes: after installing/upgrading rmarkdown, replace files in
+- reduce the size of vignettes: after installing/upgrading rmarkdown, replace files in
rmarkdown/rmd/h/bootstrap/fonts/ with empty files
- build the package using both qpdf and ghostscript to compact vignettes:
Modified: pkg/CHNOSZ/man/eqdata.Rd
===================================================================
--- pkg/CHNOSZ/man/eqdata.Rd 2019-03-09 00:43:47 UTC (rev 428)
+++ pkg/CHNOSZ/man/eqdata.Rd 2019-04-05 04:31:52 UTC (rev 429)
@@ -3,7 +3,10 @@
\alias{eqdata}
\title{Read data from an EQ6 output file}
\description{
- Extract computational results for aqueous species, solid phases, mineral saturation states, or speciation summaries at each step of reaction progress in an EQ6 output file. The results are written to a comma-separated value file that can be read by other programs.
+Extract computational results for aqueous species, solid phases, mineral saturation states, or speciation summaries at each step of reaction progress in an EQ6 output file.
+The results are written to a comma-separated value file that can be read by other programs.
+The function has been tested with output files generated by EQ3/6 version 7.1 running on a Unix platform.
+Currently it does not work for files generated by later versions.
}
\usage{
@@ -33,8 +36,7 @@
If \code{outfile} is TRUE, the result is saved in a file named like \samp{file}.\samp{property}.\code{csv}, in the same directory as \code{file}. The name of the \code{outfile} can be provided to override this naming scheme, or this argument can be set to FALSE or NULL, to turn off writing the result to a file.
- Thanks to Peter Canovas and Everett Shock for helping to test the code and offering ideas for improvements. The function has been tested with output files generated by EQ3/6 version 7.1 running on a Unix platform.
-
+ Thanks to Peter Canovas and Everett Shock for helping to test the code and offering ideas for improvements.
}
\references{
Modified: pkg/CHNOSZ/vignettes/anintro.Rmd
===================================================================
--- pkg/CHNOSZ/vignettes/anintro.Rmd 2019-03-09 00:43:47 UTC (rev 428)
+++ pkg/CHNOSZ/vignettes/anintro.Rmd 2019-04-05 04:31:52 UTC (rev 429)
@@ -118,13 +118,15 @@
install.packages("CHNOSZ")
```
-Then load the CHNOSZ package to make its functions available in your R session:
+Then load the CHNOSZ package to make its data and functions available in your R session:
```{r library_CHNOSZ}
library(CHNOSZ)
```
-Then load the `thermo` object, which contains the thermodynamic database and system settings for CHNOSZ:
-```{r data_thermo}
+CHNOSZ is now ready to go with the default thermodynamic database and an empty system definition.
+After running some calculations, you may want to "start over" with the default values.
+To clear the system settings and restore the default thermodynamic database, use <span style="color:red">`reset()`</span>.
+```{r reset}
reset()
```
@@ -155,7 +157,7 @@
Many functions in CHNOSZ have no side effects.
That is, the function only returns a result; to use the result elsewhere, it can be assigned to a variable with `<-`.
-In this document, the names of these functions are set in <span style="color:green">green text</span> (not applicable to the code chunks).
+In this document, the names of these functions are shown in <span style="color:green">green text</span> (not applicable to the code chunks).
```{marginfigure}
When they are mentioned, names of functions in the base and recommended packages of R are said to belong to R.
Example: Use R's `plot()` to plot the data.
@@ -169,7 +171,7 @@
* <span style="color:green">`diagram()`</span>: plot the results.
Some functions in CHNOSZ do have side effects: they modify the `thermo` data object in the current R session.
-In this document, the names of these functions are set in <span style="color:red">red text</span> (but not in the code chunks).
+In this document, the names of these functions are shown in <span style="color:red">red text</span> (but not in the code chunks).
Major functions with side effects are:
* <span style="color:red">`basis()`</span>: set the basis species and their chemical activities;
@@ -381,7 +383,7 @@
As expected, we get the same result from both operations.
Use <span style="color:red">`reset()`</span> to restore the units and all other settings for CHNOSZ to their defaults:
-```{r data_thermo}
+```{r reset}
```
# Properties of reactions
@@ -562,7 +564,7 @@
```
Let's not forget to clear the system settings, which were modified by <span style="color:red">`basis()`</span> and <span style="color:red">`E.units()`</span>, before running other calculations:
-```{r data_thermo, message=FALSE}
+```{r reset, message=FALSE}
```
# Using <span style="color:green">`affinity()`</span>
@@ -1527,8 +1529,8 @@
```
Now we can load the proteins and calculate their activities in metastable equilibrium as a function of `r logfO2`.
-The commented line uses <span style="color:red">`add.obigt()`</span> to revert the group additivity parameters to those present in older versions of CHNOSZ (Dick et al., 2006).
-The current database, with parameters set by <span style="color:red">`reset()`</span> and used here, contains updated group additivity parameters for the sidechain groups of methionine (LaRowe and Dick, 2012) and glycine and the protein backbone [@Kit14].
+The commented line uses <span style="color:red">`add.obigt()`</span> to load group additivity parameters that were present in older versions of CHNOSZ (Dick et al., 2006).
+The default database contains newer group additivity parameters for the sidechain groups of methionine (LaRowe and Dick, 2012) and glycine and the protein backbone [@Kit14].
```{r yeastplot, eval=FALSE, echo=1:6}
par(mfrow = c(1, 3))
@@ -2007,12 +2009,8 @@
The column names with a dot (`.`) refer to different sets of equations for calculating standard thermodynamic properties.
Aqueous species use the revised Helgeson-Kirkham-Flowers (HKF) equations (symbols before the dot), and crystalline, gas and liquid species other than `r h2o` use a general heat capacity equation.
-See <span style="color:blue">`?thermo`</span> for details about what's in the data table, and <span style="color:blue">`?hkf`</span> and <span style="color:blue">`?cgl`</span> for information about the thermodynamic equations.
+See <span style="color:blue">`?thermo`</span> for details about what's in the data table, and <span style="color:blue">`?hkf`</span> and <span style="color:blue">`?cgl`</span> for information about the equations used for thermodynamic properties.
-Another use of <span style="color:red">`add.obigt()`</span> is to add data from the file `CHNOSZ_aq.csv`, which holds provisional updates that aren't loaded by default (i.e., using <span style="color:red">`reset()`</span>).
-In this mode, only the name of the species is used as the argument.
-Currently available species are `adenine-old` and `pseudo-H4SiO4` (see [<span style="color:blue">`demo(adenine)`</span>](../demo) and the vignette, [<span style="color:blue">*Regressing thermodynamic data*</span>](eos-regress.html)).
-
## Modifying data
Use <span style="color:red">`mod.obigt()`</span> to add or modify the database in the current session.
Modified: pkg/CHNOSZ/vignettes/mklinks.sh
===================================================================
--- pkg/CHNOSZ/vignettes/mklinks.sh 2019-03-09 00:43:47 UTC (rev 428)
+++ pkg/CHNOSZ/vignettes/mklinks.sh 2019-04-05 04:31:52 UTC (rev 429)
@@ -37,7 +37,7 @@
sed -i '120,$s/<code>diagram()<\/code>/<code><a href="..\/html\/diagram.html" style="background-image:none;">diagram()<\/a><\/code>/g' anintro.html
sed -i '120,$s/<code>basis()<\/code>/<code><a href="..\/html\/basis.html" style="background-image:none;">basis()<\/a><\/code>/g' anintro.html
sed -i '120,$s/<code>species()<\/code>/<code><a href="..\/html\/species.html" style="background-image:none;">species()<\/a><\/code>/g' anintro.html
-sed -i '120,$s/<code>reset()<\/code>/<code><a href="..\/html\/reset.html" style="background-image:none;">reset()<\/a><\/code>/g' anintro.html
+sed -i '120,$s/<code>reset()<\/code>/<code><a href="..\/html\/thermo.html" style="background-image:none;">reset()<\/a><\/code>/g' anintro.html
sed -i '120,$s/<code>describe.reaction()<\/code>/<code><a href="..\/html\/util.expression.html" style="background-image:none;">describe.reaction()<\/a><\/code>/g' anintro.html
sed -i '120,$s/<code>swap.basis()<\/code>/<code><a href="..\/html\/swap.basis.html" style="background-image:none;">swap.basis()<\/a><\/code>/g' anintro.html
sed -i '120,$s/<code>water.lines()<\/code>/<code><a href="..\/html\/util.plot.html" style="background-image:none;">water.lines()<\/a><\/code>/g' anintro.html
@@ -45,7 +45,6 @@
sed -i '120,$s/<code>mosaic()<\/code>/<code><a href="..\/html\/mosaic.html" style="background-image:none;">mosaic()<\/a><\/code>/g' anintro.html
sed -i '120,$s/<code>convert()<\/code>/<code><a href="..\/html\/util.units.html" style="background-image:none;">convert()<\/a><\/code>/g' anintro.html
sed -i '120,$s/<code>mod.buffer()<\/code>/<code><a href="..\/html\/buffer.html" style="background-image:none;">mod.buffer()<\/a><\/code>/g' anintro.html
-sed -i '120,$s/<code>reset\$/<code><a href="..\/html\/thermo.html" style="background-image:none;">reset<\/a>\$/g' anintro.html
sed -i '120,$s/<code>solubility()<\/code>/<code><a href="..\/html\/solubility.html" style="background-image:none;">solubility()<\/a><\/code>/g' anintro.html
sed -i '120,$s/<code>ZC.col()<\/code>/<code><a href="..\/html\/util.plot.html" style="background-image:none;">ZC.col()<\/a><\/code>/g' anintro.html
sed -i '120,$s/<code>aminoacids(\"\")<\/code>/<code><a href="..\/html\/util.seq.html" style="background-image:none;">aminoacids(\"\")<\/a><\/code>/g' anintro.html
More information about the CHNOSZ-commits
mailing list