[CHNOSZ-commits] r142 - in pkg/CHNOSZ: . R inst man vignettes
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Sat Feb 11 13:23:32 CET 2017
Author: jedick
Date: 2017-02-11 13:23:32 +0100 (Sat, 11 Feb 2017)
New Revision: 142
Modified:
pkg/CHNOSZ/DESCRIPTION
pkg/CHNOSZ/R/revisit.R
pkg/CHNOSZ/R/util.misc.R
pkg/CHNOSZ/inst/NEWS
pkg/CHNOSZ/man/diagram.Rd
pkg/CHNOSZ/man/protein.Rd
pkg/CHNOSZ/man/read.expr.Rd
pkg/CHNOSZ/vignettes/anintro.Rmd
pkg/CHNOSZ/vignettes/vig.bib
Log:
anintro.Rmd: add proteins: normalization to residues
Modified: pkg/CHNOSZ/DESCRIPTION
===================================================================
--- pkg/CHNOSZ/DESCRIPTION 2017-02-11 04:34:19 UTC (rev 141)
+++ pkg/CHNOSZ/DESCRIPTION 2017-02-11 12:23:32 UTC (rev 142)
@@ -1,6 +1,6 @@
Date: 2017-02-11
Package: CHNOSZ
-Version: 1.0.8-31
+Version: 1.0.8-32
Title: Chemical Thermodynamics and Activity Diagrams
Author: Jeffrey Dick
Maintainer: Jeffrey Dick <j3ffdick at gmail.com>
Modified: pkg/CHNOSZ/R/revisit.R
===================================================================
--- pkg/CHNOSZ/R/revisit.R 2017-02-11 04:34:19 UTC (rev 141)
+++ pkg/CHNOSZ/R/revisit.R 2017-02-11 12:23:32 UTC (rev 142)
@@ -195,8 +195,9 @@
if(plot.it) {
if(is.null(ylim)) ylim <- extendrange(H, f=0.075)
if(is.null(xlim)) xlim <- xrange
- # format the objective name if it's DGtr
+ # format the objective name if it's DGtr or DGinf
if(objective=="DGtr") ylab <- expr.property("DGtr/2.303RT")
+ if(objective=="DGinf") ylab <- expr.property("DGinf/2.303RT")
else ylab <- objective
if(!add) thermo.plot.new(xlim=xlim, ylim=ylim, xlab=axis.label(xname),
ylab=ylab, yline=yline, cex=cex, lwd=lwd, mar=mar, side=side)
Modified: pkg/CHNOSZ/R/util.misc.R
===================================================================
--- pkg/CHNOSZ/R/util.misc.R 2017-02-11 04:34:19 UTC (rev 141)
+++ pkg/CHNOSZ/R/util.misc.R 2017-02-11 12:23:32 UTC (rev 142)
@@ -77,7 +77,7 @@
# apply the factor
act <- act * act.fact
# take the logarithms
- logact <- log10(act)
+ log10(act)
# done!
}
Modified: pkg/CHNOSZ/inst/NEWS
===================================================================
--- pkg/CHNOSZ/inst/NEWS 2017-02-11 04:34:19 UTC (rev 141)
+++ pkg/CHNOSZ/inst/NEWS 2017-02-11 12:23:32 UTC (rev 142)
@@ -1,4 +1,4 @@
-CHANGES IN CHNOSZ 1.0.8-31 (2017-02-11)
+CHANGES IN CHNOSZ 1.0.8-32 (2017-02-11)
---------------------------------------
DOCUMENTATION:
Modified: pkg/CHNOSZ/man/diagram.Rd
===================================================================
--- pkg/CHNOSZ/man/diagram.Rd 2017-02-11 04:34:19 UTC (rev 141)
+++ pkg/CHNOSZ/man/diagram.Rd 2017-02-11 12:23:32 UTC (rev 142)
@@ -151,6 +151,14 @@
\examples{
\dontshow{data(thermo)}
+## calculate the equilibrium logarithm of activity of a
+## basis species in different reactions
+basis("CHNOS")
+species(c("ethanol", "lactic acid", "deoxyribose", "ribose"))
+a <- affinity(T=c(0, 150))
+diagram(a, what="O2", legend.x="topleft", col=rev(rainbow(4)), lwd=2)
+title(main="equilibrium logfO2 for 1e-3 mol/kg of CO2 and ... ")
+
### 1-D diagrams: logarithms of activities
## Aqueous sulfur species (after Seewald, 1997 and 2001)
@@ -204,6 +212,28 @@
title(main=paste("Fe-S-O, 200 degrees C, 1 bar",
"After Helgeson, 1970", sep="\n"))
+## Mineral equilibrium activity diagram
+## After Bowers et al., 1984, p. 246
+# Consider the system denoted by BJH84 as
+# HCl-H2O-CaO-CO2-MgO-(SiO2) at 300 deg C and 1000 bar
+# HCl, CO2, O2 have zero stoichiometric coeffs in the species
+# Ca+2, Mg+2 are going to be on the diagram
+# SiO2 will be conserved (the immobile component)
+# (try changing any of the 999's, the diagram will be unaffected)
+basis(c("HCl","H2O","Ca+2","CO2","Mg+2","SiO2","O2","H+"),
+ c(999,0,999,999,999,999,999,-7))
+# we have to tell CHNOSZ which species to include; there are
+# others that could be in this system
+species(c("quartz","talc","forsterite","tremolite","diopside",
+ "wollastonite","monticellite","merwinite"))
+# calculate the chemical affinities of formation reactions
+a <- affinity("Mg+2"=c(-12,-4),"Ca+2"=c(-8,0),T=300,P=1000)
+diagram(a)
+title(main=paste("HCl-H2O-CaO-CO2-MgO-(SiO2) at 300 degrees C,",
+ "1000 bar and pH=7. After Bowers et al., 1984", sep="\n"))
+# note: Bowers et al. use different variables (e.g. (a_Ca+2)/(a_H+)^2),
+# so the plot here is not an exact reproduction
+
## pe-pH diagram for hydrated iron sulfides,
## goethite and pyrite, after Majzlan et al., 2006
# add some of these species to the database
@@ -263,20 +293,14 @@
stopifnot(species()$name[d$predominant[1, 1]]=="andalusite")
stopifnot(species()$name[d$predominant[1, 101]]=="kyanite")
stopifnot(species()$name[d$predominant[99, 101]]=="sillimanite")
-
-## calculate the equilibrium logarithm of activity of a
-## basis species in different reactions
-basis("CHNOS")
-species(c("ethanol", "lactic acid", "deoxyribose", "ribose"))
-a <- affinity(T=c(0, 150))
-diagram(a, what="O2", legend.x="topleft", col=rev(rainbow(4)), lwd=2)
-title(main="equilibrium logfO2 for 1e-3 mol/kg of CO2 and ... ")
}
\references{
Aksu, S. and Doyle, F. M. (2001) Electrochemistry of copper in aqueous glycine solutions. \emph{J. Electrochem. Soc.} \bold{148}, B51--B57. \url{http://dx.doi.org/10.1149/1.1344532}
+ Bowers, T. S., Jackson, K. J. and Helgeson, H. C., 1984. \emph{Equilibrium Activity Diagrams for Coexisting Minerals and Aqueous Solutions at Pressures and Temperatures to 5 kb and 600} \eqn{^{\circ}}{degrees }\emph{C}. Springer-Verlag, Heidelberg, 397 p. \url{http://www.worldcat.org/oclc/224591948}
+
Helgeson, H. C. (1970) A chemical and thermodynamic model of ore deposition in hydrothermal systems. \emph{Mineral. Soc. Amer. Spec. Pap.} \bold{3}, 155--186. \url{http://www.worldcat.org/oclc/583263}
Helgeson, H. C., Delany, J. M., Nesbitt, H. W. and Bird, D. K. (1978) Summary and critique of the thermodynamic properties of rock-forming minerals. \emph{Am. J. Sci.} \bold{278-A}, 1--229. \url{http://www.worldcat.org/oclc/13594862}
Modified: pkg/CHNOSZ/man/protein.Rd
===================================================================
--- pkg/CHNOSZ/man/protein.Rd 2017-02-11 04:34:19 UTC (rev 141)
+++ pkg/CHNOSZ/man/protein.Rd 2017-02-11 12:23:32 UTC (rev 142)
@@ -32,23 +32,10 @@
## Standard molal entropy of a protein reaction
basis("CHNOS")
# here we provide the reaction coefficients of the
-# proteins (per protein backbone); 'subcrt' function calculates
+# proteins (per protein backbone); subcrt() calculates
# the coefficients of the basis species in the reaction
-s <- subcrt(c("CSG_METTL","CSG_METJA"), c(-1/530,1/530),
+s <- subcrt(c("CSG_METTL", "CSG_METJA"), c(-1/530, 1/530),
T=seq(0, 350, length.out=50))
-thermo.plot.new(xlim=range(s$out$T), ylim=range(s$out$S),
- xlab=axis.label("T"), ylab=axis.label("DS0r"))
-lines(s$out$T, s$out$S)
-# do it at high pressure as well
-s <- subcrt(c("CSG_METTL","CSG_METJA"), c(-1/530,1/530),
- T=seq(0,350,length.out=50), P=3000)
-lines(s$out$T, s$out$S, lty=2)
-# label the plot
-title(main=paste("Standard molal entropy\n",
- "P = Psat (solid), P = 3000 bar (dashed)"))
-s$reaction$coeff <- round(s$reaction$coeff, 3)
-dsr <- describe.reaction(s$reaction, iname=c(1,2))
-text(170, -3, dsr, cex=0.8)
### Equilibrium activity diagrams
Modified: pkg/CHNOSZ/man/read.expr.Rd
===================================================================
--- pkg/CHNOSZ/man/read.expr.Rd 2017-02-11 04:34:19 UTC (rev 141)
+++ pkg/CHNOSZ/man/read.expr.Rd 2017-02-11 12:23:32 UTC (rev 142)
@@ -86,41 +86,31 @@
# look for proteins described as "Complement"
read.expr(file, "name", "log10(pg/ml)", list(description="Complement"))
-## speciation diagram for ER.to.Golgi proteins (COPII coat
-## proteins) as a function of logfO2, after Dick, 2009
-# use old parameters for [Met] (Dick et al., 2006)
-mod.obigt("[Met]", G=-35245, H=-59310)
-y <- yeastgfp("ER.to.Golgi")
-# don't use those with NA abundance
-ina <- is.na(y$abundance)
-# get the amino acid compositions of the proteins
-aa <- more.aa(y$protein[!ina], "Sce")
-# add proteins to thermo$protein
-ip <- add.protein(aa)
-# use logarithms of activities of proteins such
-# that total activity of residues is unity
-pl <- protein.length(ip)
-logact <- unitize(rep(1, length(ip)), pl)
-# load the proteins
+## Localizations and abundances of proteins from YeastGFP are used here
+## to calculate an abundance-weighted average of amino acid compositions of proteins
+## in different subcellular compartments of yeast.
+## This figure is similar to Fig. 3 of Dick (2009).
+locations <- yeastgfp()
+gfp <- yeastgfp(locations)
+aa <- more.aa(gfp$protein, "Sce")
+for(i in 1:length(locations)) {
+ avgaa <- aasum(aa[[i]], gfp$abundance[[i]], average=TRUE, protein=locations[i])
+ add.protein(avgaa)
+}
basis("CHNOS+")
-a <- affinity(O2=c(-80, -73), iprotein=ip, loga.protein=logact)
-# make a speciation diagram
-e <- equilibrate(a, normalize=TRUE)
-diagram(e, ylim=c(-4.9, -2.9), format.names=FALSE)
-# where we are closest to experimental log activity
-logfO2 <- rep(-78, length(ip))
-abline(v=logfO2[1], lty=3)
-# scale experimental abundances such that
-# total activity of residues is unity
-logact.expt <- unitize(log10(y$abundance[!ina]), pl)
-# plot experimental log activity
-points(logfO2, logact.expt, pch=16)
-text(logfO2+0.5, logact.expt, y$protein[!ina])
-# add title
-title(main=paste("ER.to.Golgi; points - relative abundances",
- "from YeastGFP. Figure after Dick, 2009",sep="\n"))
-# restore default thermodynamic database
-data(thermo)
+species(locations, "Sce")
+a <- affinity(O2=c(-82, -65))
+e <- equilibrate(a, loga.balance=0, normalize=TRUE)
+mycolor <- topo.colors(length(locations))
+diagram(e, names=locations, ylim=c(-5, -3), legend.x=NA, col=mycolor, lwd=2)
+dp <- describe.property(c("T", "P"), c(25, 1))
+db <- describe.basis(ibasis=(1:6)[-5])
+legend("topright", legend=c(dp, db), bty="n")
+## Notable features include: proteins in the early Golgi, endoplasmic reticulum (ER)
+## and vacuole are chemically the most stable relative to those in other locations in the cell;
+## proteins in the vacuole are very oxidized; the stability of proteins decreases going from
+## early Golgi to Golgi to late Golgi; the least stable proteins (or most energetic)
+## are found in the microtubules and bud neck.
#############################
## examples using stress() ##
Modified: pkg/CHNOSZ/vignettes/anintro.Rmd
===================================================================
--- pkg/CHNOSZ/vignettes/anintro.Rmd 2017-02-11 04:34:19 UTC (rev 141)
+++ pkg/CHNOSZ/vignettes/anintro.Rmd 2017-02-11 12:23:32 UTC (rev 142)
@@ -381,7 +381,7 @@
text(5, 5, describe.reaction(hydrogenotrophic$reaction), adj=1)
```
-## Affinity: not the standard state Gibbs energy
+## Chemical affinity
Usually, <span style="color:green">`subcrt()`</span> returns only standard state thermodynamic properties.
```{marginfigure}
@@ -460,7 +460,7 @@
## Activity coefficients
-XXX Example using <span style="color:green">`nonideal()`</span> ...
+XXX Example using <span style="color:green">`nonideal()`</span> ... Alberty, 2003, Fig. 1.4-1.5 (p. 9-10, 235-236)
# <span style="color:green">`affinity()`</span>, species of interest, and potential diagrams
@@ -566,7 +566,7 @@
We use <span style="color:green">`mosaic()`</span> to generate and combine diagrams for each candidate basis species (H<sub>2</sub>S, HS<sup>-</sup>, HSO<sub>4</sub><sup>-</sup>, or SO<sub>4</sub><sup>-2</sup>) as a function of Eh and pH.
The key argument is `bases`, which identifies the candidate basis species (starting with the one in the current basis).
-The other arguments, like those of <span style="color:green">`affinity()`</span>, specify the ranges of the variables; `res` indicates the grid resolution to use for each variable (higher than the default).
+The other arguments, like those of <span style="color:green">`affinity()`</span>, specify the ranges of the variables; `res` indicates the grid resolution to use for each variable (higher than the default of 128).
The first call to <span style="color:green">`diagram()`</span> plots the species of interest; the second adds the predominance fields of the basis species.
Finally, <span style="color:green">`water.lines()`</span> is used to add the stability limits of water at the given temperature.
@@ -589,7 +589,7 @@
For instance, we can use H<sub>2</sub> or `r o2` in place of *e*<sup>-</sup>.
To do that, let's write a function to swap those basis species and make a diagram.
We use R's `do.call()` to construct the argument list for <span style="color:green">`mosaic()`</span>; this way, the name of the `newvar` argument to our function indicates the chosen variable.
-```{r mosaicfun, fig.fullwidth=TRUE, fig.width=10.5, fig.height=3, small.mar=TRUE, dpi=dpi, out.width="100%", message=FALSE, results="hide", cache=TRUE, fig.cap="Different projections (defined by the basis species) of the same thermodynamic system. The choice between them depends on convenience rather than correctness.", pngquant=pngquant}
+```{r mosaicfun, fig.fullwidth=TRUE, fig.width=9, fig.height=3, small.mar=TRUE, dpi=dpi, out.width="85%", message=FALSE, results="hide", cache=TRUE, fig.cap="Different projections (defined by the basis species) of the same thermodynamic system. The choice between them depends on convenience rather than correctness.", pngquant=pngquant}
mosaicfun <- function(newvar, T=200, res=300) {
swap.basis("e-", names(newvar))
if(names(newvar) == "O2") basis("O2", "gas")
@@ -597,10 +597,9 @@
m1 <- do.call(mosaic, mosaicargs)
diagram(m1$A.species, lwd=2, fill=rev(topo.colors(10)))
diagram(m1$A.bases, add=TRUE, col="blue", col.names="blue", lty=3)
- title(main=expr.species(names(newvar)))
swap.basis(names(newvar), "e-")
}
-layout(t(matrix(c(1, 1, 2, 2, 3, 3, 0))))
+par(mfrow=c(1, 3))
mosaicfun(list(Eh=c(-1, 1, res)))
mosaicfun(list(H2=c(-15, 5, res)))
mosaicfun(list(O2=c(-70, 0, res)))
@@ -863,8 +862,8 @@
The groups are identified by the current species numbers in a list, where the list elements are given names that will appear on the diagram.
When summing the activities of species in the groups, each activity is multiplied first by the balance coefficient on that species.
Therefore, the total activity is that of a basis species (or of an element that only in that basis species, like carbon in this example).
-```{r groups_diagram, echo=2:4, eval=FALSE}
-layout(t(matrix(c(1, 1, 2, 2, 3, 3, 0))))
+```{r groups_diagram, echo=1:4, eval=FALSE}
+par(mfrow=c(1, 3))
groups <- list(inorganic=ii, alcohols=ia, ketones=ik,
`carboxylic acids`=c(ic, ica), alkenes=ie)
diagram(e, alpha=TRUE, groups=groups, legend.x=NA)
@@ -886,7 +885,7 @@
We do this by setting the names and line types for the *other* species to values that prevent them from being plotted:
```{r groups_diagram, echo=-(1:4), eval=FALSE}
```
-```{r groups_diagram, fig.fullwidth=TRUE, fig.width=10.5, fig.height=3, small.mar=TRUE, dpi=dpi, out.width="100%", echo=FALSE, message=FALSE, results="hide", cache=TRUE, pngquant=pngquant}
+```{r groups_diagram, fig.fullwidth=TRUE, fig.width=9, fig.height=3, small.mar=TRUE, dpi=dpi, out.width="85%", echo=FALSE, message=FALSE, results="hide", cache=TRUE, pngquant=pngquant}
```
## Choosing a different balance
@@ -901,7 +900,7 @@
basis("CO2", "gas")
swap.basis("NH3", "N2")
species(aminoacids(""))
-a <- affinity(O2=c(-50, -25), CO2=c(-10, 15), T=250, P=265)
+a <- affinity(O2=c(-50, -25, 300), CO2=c(-10, 15, 300), T=250, P=265)
aa.ZC <- ZC(info(aminoacids("")))
col <- ZC.col(aa.ZC)
```
@@ -1090,8 +1089,84 @@
By projecting the compositions of proteins into the "QEC" set of basis species, *n*̅<sub>`r o2`</sub> emerges as a strong indicator of oxidation state, while *n*̅<sub>`r h2o`</sub> is a relatively non-correlated (i.e. independent) compositional variable.
These independent variables make it easier to distinguish the effects of oxidation and hydration state in proteomic experiments [@Dic17].
-## Normalizing for different lengths
+## Normalization to residues
+As with other systems, a balance must be chosen for calculations of the metastable equilibrium distribution for proteins.
+Balancing on the number of backbone units (the length of the proteins) seems a reasonable choice given the polymeric structure of proteins.
+```{marginfigure}
+Balancing on one of the basis species remains a possibility, using the `balance` argument in <span style="color:green">`equilibrate()`</span> or <span style="color:green">`diagram()`</span>.
+```
+However, there is an additional consideration: owing to the large size of proteins compared to the basis species, the distribution of *proteins* in metastable equilibrium has many orders of magnitude separation between the activities of the dominant and less-dominant proteins.
+The metastable coexistence of the *residues* (i.e. per-residue formulas, or residue equivalents) of the same proteins spans a much smaller range of chemical activities.
+In CHNOSZ, the calculation of metastable equilibrium activities of the residue equivalents is referred to as *normalization*.
+```{marginfigure}
+See the vignette <span style="color:blue">*Equilibrium in CHNOSZ*</span> for other examples using normalization.
+```
+
+To take an example, let's look at the metastable equilibrium distribution of selected proteins in the ER-to-Golgi compartment of *S. cerevisiae* (yeast).
+This example brings in a few other functions we haven't seen yet: <span style="color:green">`yeastgfp()`</span>, <span style="color:green">`unitize()`</span>, and <span style="color:green">`revisit()`</span>.
+<span style="color:green">`yeastgfp()`</span> queries a data file in CHNOSZ for the names and relative abundances of proteins taken from the YeastGFP study of @GHB_03.
+There are six proteins identified in the ER-to-Golgi compartment; one has NA abundance, so it is excluded from the comparisons.
+```{r yeastgfp}
+y <- yeastgfp("ER.to.Golgi")
+ina <- is.na(y$abundance)
+```
+
+Next, we get the amino acid compositions of the proteins and add them to thermo$protein.
+```{r add_protein_yeast, message=FALSE}
+aa <- more.aa(y$protein[!ina], "Sce")
+ip <- add.protein(aa)
+```
+
+The YeastGFP study reported absolute abundances of molecules, but the thermodynamic calculations give relative chemical activities of the proteins.
+In order to make a comparison between them, we use <span style="color:green">`unitize()`</span> to scale the abundances or activities of proteins (in logarithmic units) such that the total abundance or activity of residue equivalents is unity.
+To do that, we must have the lengths of the proteins.
+The first call to <span style="color:green">`unitize()`</span> generates equal logarithms of activities of proteins for unit total activity of residues; this is used as the reference state for <span style="color:green">`affinity()`</span>.
+The second call to <span style="color:green">`unitize()`</span> scales the logarithms of experimental abundances for unit total activity of residues; this is used for plotting a comparison with the theoretical results.
+```{r unitize}
+pl <- protein.length(ip)
+logact <- unitize(numeric(5), pl)
+logabundance <- unitize(log10(y$abundance[!ina]), pl)
+```
+
+Now we can load the proteins and calculate their activities in metastable equilibrium as a function of `r logfO2`.
+```{marginfigure}
+The commented line uses <span style="color:red">`mod.obigt()`</span> to revert the parameters of the methionine sidechain group to those present in older versions of CHNOSZ (Dick et al., 2006).
+The current database, with parameters instantiated by <span style="color:red">`data(thermo)`</span> and used here, contains updated group additivity parameters for methionine (LaRowe and Dick, 2012).
+```
+```{r yeastplot, eval=FALSE, echo=1:6}
+par(mfrow=c(1, 3))
+basis("CHNOS+")
+#mod.obigt("[Met]", G=-35245, H=-59310)
+a <- affinity(O2=c(-80, -73), iprotein=ip, loga.protein=logact)
+e <- equilibrate(a)
+diagram(e, ylim=c(-5, -2), format.names=FALSE, legend.x=NA, col=1:5, lwd=2)
+e <- equilibrate(a, normalize=TRUE)
+diagram(e, ylim=c(-5, -2.5), format.names=FALSE, legend.x=NA, col=1:5, lwd=2)
+abline(h=logabundance, lty=1:5, col=1:5)
+revisit(e, "DGinf", logabundance)
+```
+
+Oh! The proteins look very non-coexistent in metastable equilibrium.
+We can get a different view by using per-residue rather than per-protein reactions via the `normalize` argument for <span style="color:green">`equilibrate()`</span>:
+```{marginfigure}
+The normalization step is followed by conversion of activities of residues to activities of proteins; that conversion can be skipped using the `as.residue` argument in <span style="color:green">`equilibrate()`</span>.
+```
+```{r yeastplot, eval=FALSE, echo=7:9}
+```
+
+The experimental relative abundances are plotted as thin horizontal lines with the same style and color as the thicker curved lines calculated for metastable equilibrium.
+With the exception of YNL049C, the overlap between the calculations and experiments looks to be greatest near the middle-left part of the figure.
+The <span style="color:green">`revisit()`</span> function offers some statistical and thermodynamic measures that can quantify this comparison.
+Here, we plot the free energy associated with the information-theoretic "relative entropy" or Kullback-Leibler divergence:
+```{r yeastplot, eval=FALSE, echo=10}
+```
+```{r yeastplot, fig.fullwidth=TRUE, fig.width=7.5, fig.height=2.5, small.mar=TRUE, dpi=100, out.width="85%", echo=FALSE, message=FALSE, results="hide", cache=TRUE, fig.cap="ER-to-Golgi proteins: calculations without and with normalization, and free energy difference between experimental and normalization-calculated abundances.", pngquant=pngquant}
+```
+
+The minimum free energy difference occurs near `r logfO2` = -78.
+This agrees with the assessment shown in Figure 4 of @Dic09 (note that the old methionine sidechain group was used in that study).
+
## Adding proteins
In the Rubisco example above, we saw the use of <span style="color:green">`read.fasta()`</span> to read amino acid sequences from a FASTA file.
@@ -1221,7 +1296,7 @@
We read a data file of amino acid compositions produced in that study, taking those labelled "transferase".
Then we add the proteins and get their indices using <span style="color:red">`add.protein()`</span>, set the basis, calculate the affinities, and make a potential diagram with temperature and activity of dissolved hydrogen as variables:
-```{r bison_transferase, fig.margin=TRUE, fig.width=4, fig.height=4, small.mar=TRUE, dpi=dpi, out.width="100%", echo=FALSE, results="hide", message=FALSE, fig.cap='Potential diagram for metagenomically identified sequences of transferase proteins in the outflow channel of Bison Pool hot spring. See also the vignette <span style="color:blue">*Hot-spring proteins in CHNOSZ*</span>.', cache=TRUE, pngquant=pngquant}
+```{r bison_transferase, fig.margin=TRUE, fig.width=4, fig.height=4, small.mar=TRUE, dpi=dpi, out.width="100%", echo=FALSE, results="hide", message=FALSE, fig.cap='Potential diagram for metagenomically identified sequences of transferases in the outflow channel of Bison Pool hot spring. See also the vignette <span style="color:blue">*Hot-spring proteins in CHNOSZ*</span>.', cache=TRUE, pngquant=pngquant}
aa <- read.aa(system.file("extdata/protein/DS11.csv", package="CHNOSZ"))
aa <- aa[grep("transferase", aa$protein), ]
ip <- add.protein(aa)
@@ -1229,7 +1304,8 @@
basis(c("HCO3-", "H2O", "NH3", "HS-", "H2", "H+"))
basis(c("HCO3-", "NH3", "HS-", "H+"), c(-3, -4, -7, -7.933))
T <- c(50, 100)
-a <- affinity(T = T, H2 = c(-7, -4), iprotein = ip)
+res <- 300
+a <- affinity(T = c(T, res), H2 = c(-7, -4, res), iprotein = ip)
fill <- ZC.col(ZC(protein.formula(ip)))
diagram(a, normalize = TRUE, fill = fill, names = 1:5, format.names=FALSE)
logaH2 <- function(T) -11 + T * 3/40
@@ -1262,10 +1338,18 @@
## Messages from functions
-(Look at messages in calculation above: groups?)
+(Look at messages in calculation above: groups, ER-to-Golgi?)
# Functions outside of the main workflow
-transfer, wjd, eqdata, RH2obigt, EOSregress, anim.
+transfer, wjd, eqdata, RH2obigt, EOSregress, anim, taxonomy
Gibbs energy minimization with amino acids: [Cob13]?
+
+# Document history
+
+* 2010-09-30 Initial version.
+* 2011-08-15 Add browse.refs(); modifying database hint changed to help(thermo).
+* 2012-06-16 Add “More activity diagrams”.
+* 2015-05-14 Add warning about internal consistency of thermodynamic data.
+* 2017-02-15 Complete rewrite; switch from Sweave to knitr (Tufte style).
Modified: pkg/CHNOSZ/vignettes/vig.bib
===================================================================
--- pkg/CHNOSZ/vignettes/vig.bib 2017-02-11 04:34:19 UTC (rev 141)
+++ pkg/CHNOSZ/vignettes/vig.bib 2017-02-11 12:23:32 UTC (rev 142)
@@ -55,7 +55,7 @@
@Article{Dic09,
author = {Dick, Jeffrey M.},
journal = {BMC Systems Biology},
- title = {Calculation of the relative metastabilities of proteins in subcellular compartments of \emph{Saccharomyces cerevisiae}},
+ title = {Calculation of the relative metastabilities of proteins in subcellular compartments of \emph{{S}accharomyces cerevisiae}},
year = {2009},
volume = {3},
pages = {75},
@@ -114,6 +114,17 @@
url = {http://www.worldcat.org/oclc/517586},
}
+ at Article{GHB_03,
+ author = {Ghaemmaghami, Sina and Huh, Won-Ki and Bower, Kiowa and Howson, Russell W. and Belle, Archana and Dephoure, Noah and O'Shea, Erin K. and Weissman, Jonathan S.},
+ journal = {Nature},
+ title = {Global analysis of protein expression in yeast},
+ year = {2003},
+ volume = {425},
+ number = {6959},
+ pages = {737--741},
+ doi = {10.1038/nature02046},
+}
+
@Incollection{Hel70c,
author = {Helgeson, Harold C.},
booktitle = {Fiftieth Anniversary Symposia},
More information about the CHNOSZ-commits
mailing list