Description Usage Arguments Value See Also Examples
View source: R/plot.FitSigma.R
plot.FitSigma
plots the fitted seed viability/survival curve from a
FitSigma
object as an object of class ggplot
.
1 2 |
x |
An object of class |
limits |
logical. If |
annotate |
logical. If |
... |
Default plot arguments. |
The plot of the seed viability curve as an object of class
ggplot
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | data(seedsurvival)
df <- seedsurvival[seedsurvival$crop == "Soybean" &
seedsurvival$moistruecontent == 7 &
seedsurvival$temperature == 25,
c("storageperiod", "rep",
"viabilitypercent", "sampsize")]
#----------------------------------------------------------------------------
# Generalised linear model with probit link function (without cv)
#----------------------------------------------------------------------------
model1a <- FitSigma(data = df, viability.percent = "viabilitypercent",
samp.size = "sampsize", storage.period = "storageperiod",
generalised.model = TRUE)
plot(model1a)
#----------------------------------------------------------------------------
# Generalised linear model with probit link function (with cv)
#----------------------------------------------------------------------------
model1b <- FitSigma(data = df, viability.percent = "viabilitypercent",
samp.size = "sampsize", storage.period = "storageperiod",
generalised.model = TRUE,
use.cv = TRUE, control.viability = 98)
plot(model1b)
#----------------------------------------------------------------------------
# Linear model after probit transformation (without cv)
#----------------------------------------------------------------------------
model2a <- FitSigma(data = df, viability.percent = "viabilitypercent",
samp.size = "sampsize", storage.period = "storageperiod",
generalised.model = FALSE)
plot(model2a)
#----------------------------------------------------------------------------
# Linear model after probit transformation (with cv)
#----------------------------------------------------------------------------
model2b <- FitSigma(data = df, viability.percent = "viabilitypercent",
samp.size = "sampsize", storage.period = "storageperiod",
generalised.model = FALSE,
use.cv = TRUE, control.viability = 98)
plot(model2b)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.