diff --git a/cran-comments.md b/cran-comments.md
index 8e3b8d1..9457cb5 100644
--- a/cran-comments.md
+++ b/cran-comments.md
@@ -1,18 +1,27 @@
## Note
Added support for computing moments and statistics.
+Changed doi format (brackets) in DESCRIPTION according to
+comment from Uwe Ligges from
+10.1641/0006-3568(2001)051[0341:lndats]2.0.co;2
+to
+10.1641/0006-3568(2001)051%5B0341:lndats%5D2.0.co;2
+
+And changed back to original doi after second comment
+by Uwe Ligges
+
+
## Test environments
+with old doi
* local R 3.4.4 on Mint17 64bit
* Ubuntu 14.04.5 LTS (on travis-ci), 14.04
* win-builder (devel)
* R-Hub
-## R CMD check results
-There were no ERRORs nor WARNINGs
-
-Note on wrong doi: I checked that the doi correctly resolves
-http://dx.doi.org/10.1641%2F0006-3568(2001)051[0341%3Alndats]2.0.co%3B2
-
+with updated doi
+* local R 3.4.4 on Mint17 64bit
+## R CMD check results
+Note on problem with doi
\ No newline at end of file
diff --git a/inst/docu/varianceBySigmaAndExpected.Rmd b/inst/docu/varianceBySigmaAndExpected.Rmd
index 4b7e75e..58d4193 100644
--- a/inst/docu/varianceBySigmaAndExpected.Rmd
+++ b/inst/docu/varianceBySigmaAndExpected.Rmd
@@ -45,16 +45,18 @@ lines(dnorm(xPred, m, sqrt(V))~xPred, col = "blue", lty = "dashed")
lines(dlnorm(xPred, mu, sigma)~xPred, col = "green")
```
```{r}
-df <- data.frame(nu = c(0.05,0.1,0.2,0.5,1,2,5,10,20))
-df$sigmaStar = sqrt(df$nu^2 + 1)
+df <- data.frame(cv = c(0.05,0.1,0.2,0.5,1,2,5,10,20))
+df$sigma = sqrt(log(df$cv^2 + 1))
+df$sigmaStar <- exp(df$sigma)
+#df$cvRev <- sqrt(exp(log(df$sigmaStar)^2) - 1)
df
```
```{r}
-plot(sigmaStar ~ nu, df[1:3,])
+plot(sigmaStar ~ cv, df[1:3,])
```
```{r}
sigmaStar <- 1.2
-(nu <- sqrt(sigmaStar^2 - 1))
+(cv <- sqrt(exp(log(sigmaStar)^2) - 1))
```
diff --git a/inst/docu/varianceBySigmaAndExpected.nb.html b/inst/docu/varianceBySigmaAndExpected.nb.html
index 62d7b97..e4efa4a 100644
--- a/inst/docu/varianceBySigmaAndExpected.nb.html
+++ b/inst/docu/varianceBySigmaAndExpected.nb.html
@@ -253,10 +253,10 @@
testing variance computation with expected value an
\]
-
+
n = 1e4
sigma = log(1.2)
-sigma = log(1.41)
+#sigma = log(1.41)
mu = log(10)
logR = rnorm(n, mu, sigma)
R = exp(logR)
@@ -266,69 +266,55 @@ testing variance computation with expected value an
#
m = exp(mu + sigma^2/2)
V = (exp(sigma^2) - 1)*m^2
-c(meanR, m)
+c(meanR, m)
+c(sdR, sqrt(V), sqrt(V2))
-
-[1] 10.61435 10.60804
-
-
-c(sdR, sqrt(V), sqrt(V2))
-
-
-[1] 3.768687 3.755077 3.755077
-
-
+
xPred <- seq(-2,22,length.out = 101)
plot(density(R), xlim = c(-2,22), lty = "dotted")
-abline(v = meanR)
-
-
-lines(dnorm(xPred, m, sqrt(V))~xPred, col = "blue", lty = "dashed")
+abline(v = meanR)
+lines(dnorm(xPred, m, sqrt(V))~xPred, col = "blue", lty = "dashed")
lines(dlnorm(xPred, mu, sigma)~xPred, col = "green")
-
-
-
-
-df <- data.frame(nu = c(0.05,0.1,0.2,0.5,1,2,5,10,20))
-df$sigmaStar = sqrt(df$nu^2 + 1)
+
+df <- data.frame(cv = c(0.05,0.1,0.2,0.5,1,2,5,10,20))
+df$sigma = sqrt(log(df$cv^2 + 1))
+df$sigmaStar <- exp(df$sigma)
+df$cvRev <- sqrt(exp(log(df$sigmaStar)^2) - 1)
df
-
+
-
-plot(sigmaStar ~ nu, df[1:3,])
+
+plot(sigmaStar ~ cv, df[1:3,])
-
-
-
-
+
sigmaStar <- 1.2
-(nu <- sqrt(sigmaStar^2-1))
+(cv <- sqrt(exp(log(sigmaStar)^2) - 1))
-
-[1] 0.663325
+
+[1] 0.1838472
-LS0tCnRpdGxlOiAidGVzdGluZyB2YX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