Displaying 20 results from an estimated 200 matches similar to: "Problem with ode"
2010 Apr 25
1
Manipulating text files
Dear R Community,
I am trying to optimize a water quality model that I am using. Based on conversations with others more familiar with what I am doing I plan to implement DEOptim to do this. The water quality model is interfaced through a GUI. I have the input file necessary to alter parameters and run the model as a text file.
To do the optimization I have figured out the general procedure
2018 Apr 12
1
ODE
Hello All,
I'm struggling to solve this ODE using R,
vdpol <- function (h, v, t) (
list(c (
-0.1*v/(pi*(2*10*h-h^2)),
(v = (-0.1*v/(pi*(2*10*h-h^2))^2) + 2*9.81*h))
))
library(deSolve)
yini <- (c(h = 20, v=0))
nonstiff <- ode(y = yini, func = vdpol,
times= seq(0, 30, by =
2016 Apr 26
0
vectors of equations in ode / desolve
Hello,
I have a syntactic problem with ode. How do I specify vectors of
equations in ordinary differential equation systems. (i.e. in my case I
want to simulate an a priory undefined number of species that have
different parameters but the same behaviour)
I demonstrate this using the Lotka Volterra example. The code below does
not work and I have not a good idea how to specify this right.
##
2019 Feb 14
0
Proposed speedup of spec.pgram from spectrum.R
Hello,
I propose two small changes to spec.pgram to get modest speedup when
dealing with input (x) having multiple columns. With plot = FALSE, I
commonly see ~10-20% speedup, for a two column input matrix and the speedup
increases for more columns with a maximum close to 45%. In the function as
it currently exists, only the upper right triangle of pgram is necessary
and pgram is not returned by
2014 Sep 16
1
Changepoint analysis--is it possible to attribute changpoints to explanatory variables?
Hello,
I would like to evaluate the relationship between flows and phytoplankton abundance (or Chlorophyll a concentrations) using a changepoint analysis.? Specifically, I have two study questions:
Study Question 1: Are there certain flow thresholds that result in spikes in phytoplankton abundance?
Study Question 2: Are the duration of certain flows important for phytoplankton abundance (e.g.,
2006 Sep 20
3
committing multiple speculations in a single probe
While using DTrace to track down a problem recently, we came across an
unexpected restriction: the compiler will not permit different
speculations to be committed in the same instance of a probe identifier.
For instance, consider the following useless D script:
#!/usr/sbin/dtrace -s
#pragma D option nspec=2
BEGIN {
spec1 = speculation();
spec2 = speculation();
}
END {
2005 Sep 14
1
Long lines with Sweave
I have used Sweave a lot the latest year, but never really used any long
function calls.
If I have code which look like this
-------------------------------------------------------------
gof <- benthic.flux(ID="Gulf of Finland",
meas.conc=conc,
bw.conc=bw.conc,
time=times,
2013 Jan 04
1
plm random effect: the estimated variance of the individual effect is negative
Matteo,
I fully agree with David: please read the posting guide.
Anyway, the error message says it all: "the estimated variance of the
individual effect is negative". See e.g. the "basic panel" chapter (10
or 11) in Wooldridge's "Econometric Analysis of XS and Panel Data" to
understand why this may happen.
Stata's behaviour is (as far as I remember) to
2009 Jul 09
1
ggplot2: geom_errorbarh()
Hi all,
quick question: is the optional command "width" effective in the
geom_errorbarh() layer of ggplot?
Cause I can't get it works on this graph
http://www.4shared.com/file/116919103/93488d88/iso_2PrsH.html
pdf(file = "iso_2PrsH.pdf", width = 7, height = 7)
NC60.iso.graph<-ggplot(
NC60.DATA
,aes(Ce,Qe)) +
geom_point(col=MaCouleur1, size=4) +
2008 May 13
1
Bubble plot pie chart map
Hello,
I am currently trying to show the abundance of two species of
zooplankton within the North Sea as pie chart bubble plots. I followed
Werner Wernersen's advice in R help
(http://finzi.psych.upenn.edu/R/Rhelp02a/archive/48644.html) and used
Paul Murrell's paper "Integrating Grid Graphics Output with Base
Graphics Output" (in R News) to try and do this (using the gridBase
2007 Nov 21
1
Different freq returned by spec.ar() and spec.pgram()
Dear list,
I've recently become interested in comparing the spectral estimates
using the different methods ("pgram" and "ar") in the spectrum()
function in the stats package.
With many thanks to the authors of these complicated functions, I
would like to point out what looks to me like a bit of an
inconsistency -- but I would not be surprised if there is good
reasoning
2008 Jan 16
1
Probability weights with density estimation
I am a physician examining an NHANES dataset available at the NCHS
website:
http://www.cdc.gov/nchs/about/major/nhanes/nhanes2005-2006/demo_d.xpt
http://www.cdc.gov/nchs/about/major/nhanes/nhanes2005-2006/hdl_d.xpt
http://www.cdc.gov/nchs/about/major/nhanes/nhanes2005-2006/tchol_d.xpt
Thank you to the R authors and the foreign package authors in
particular. Importing from the SAS export
2011 Apr 20
3
succession time series graph
Dear gracious R community,
I would like to produce charts of phytoplankton biomass changes
through time. Each species has a line, and the biomass varies in
mirror form along the line for each species along the X time axis.
Here is an example of what I'd like to do:
http://www.er.uqam.ca/nobel/r30240/Succession.jpg
Any suggestions?
Thanks
David Bird
UQAM, Montreal
2013 Sep 18
1
ggplot2: changing strip text in facet_grid and a legend text problem
Hi,
Dummy data script and scripts are attached below.
I would like to change the plot to look like this:
2011 Aug 16
3
Text wrap
Hi everyone.
I have a long label that I would like to split. I found that I could use
"strwrap" for simple text. However, this is not working with this label:
str = expression(paste("< 20 ?m phytoplankton ","(cells ? ",mL^-1,")"))
plot(...., ylab = strwrap(str,20),...)
I suspect this is because I'm using "expression" for form my label.
2008 Sep 23
1
superscript text style in axis label in graph
Hi all,
I'd like to use superscript or subscript in the axis label of a graph. Is
that possible in R?
For instance in xlab="Ce (mmol/m3)", I'd need the "3" of cubic meter in
superscript.
Regards/Cordialement
-------------
Benoit Boulinguiez
Ph.D
Ecole de Chimie de Rennes (ENSCR) Bureau 1.20
Equipe CIP UMR CNRS 6226 "Sciences Chimiques de Rennes"
Campus
2008 Sep 30
1
Using sub to get captions in barplots
All,
I've been using "sub" (subtitle) instead of "main" such that captions are
below figures produced by xyplot. This works fine and captions are on a
single line. However, when I try this for bar plots with error bars
(altering the error.bars function form Crawley's The R Book, see below), the
captions are split on more than 1 line. Is there a way to get the
2012 Sep 08
1
Thanks for helping - back to the community?
DeaR R-fellows,
I got a lot of help from you concerning the generation of heat maps,
so I was able to write and work with a script for this purpose at
last. Some visitors of our Ecological Station asked about the
generation of the graphs and so I decided to write down a small
description.
Is it adviseable to publish the link to the article in an R-wiki
(which?) so I can give back a little to the
2012 Sep 09
1
PCA legend outside of PCA plot
Hi All,
I have been trying to get to plot my PCA legend outside of the PCA plot,
but success still alludes me.
Can you guys please advise how I can achieve this. I used locater() to
obtain coordinates for below the Comp.1 axis. Using these coordinates the
legend disappears.
Below is the code for the PCA and legend.
Thanks in advance for the help.
Regards
Tinus
r.cols <-
2011 Jan 04
3
How to make a Cluster of Clusters
Dear R-help,
In my Master thesis I measured 10 variables from 18 lakes. These
measurements were taken 4 times a year in 3 depths, so I have 12
samples from each lake. I know that 12 samples can not be treated as
replications, since they don't correspond to the same environmental
characteristics and are not statistically independent, but I want to
use these 12 samples as an estimate of an