search for: alj27

Displaying 10 results from an estimated 10 matches for "alj27".

2012 Mar 26
2
y needing more than 2 functions
Dear all, I'm aware if y has two separate functions (depending on the conditions of x) you can use the ifelse function to separate y into two separate functions depending on input. How do you do this if there a multiple different conditions for x? for example, y fits the following between t>0 & t<15----->function(t) t^2, y fits the following between t>15 &
2013 Feb 19
1
latin hypercube sampling
Hi all, I am attempting to use latin hypercube sampling to sample different variable functions in a series of simultaneous differential equations. There is very little code online about lhs or clhs, so from different other help threads I have seen, it seems I need to create a probability density function for each variable function, and then use latin hypercube sampling on this pdf. So far, I
2011 Nov 10
2
How does once import a function from an imported script?
Hi all, I am trying to import some functions into a script and am having difficulty in doing so. I am able to import a series of functions from a .tex file into my script, and call on each function by column name, however R reads them as data rather than as functions and I am struggling with the syntax to make R read them as a function instead. Below is a small set of the things I have tried:
2012 Jan 08
0
Adding a migration element to a deterministic spatial model
Hi all, I've been working with a friend's model that is a spatial model consisting of 4 patches. She uses the code found below to add migration between the patches for the three species of concern. When I run a script incorporating this code, all four patches run independently without migration occuring. When I type m1[1,2] into the workspace to see if it will return a figure, it returns,
2013 Mar 14
0
Error with epiR and sensitivity
Hi everyone, I emailed yesterday thinking I had a problem with reading matrix information as numerical output into epiR. After working on the data frame today, I realise it's a problem with the data itself rather than the syntax. An original data frame of min max T1 1.500000e+01 3.999954e+01 SE1 0.000000e+00 1.000000e+00 PRE
2013 Apr 12
0
kNNimpute error
Hi all, I'm trying to use kNNimpute in the imputation package to fill in missing precipitation data for a data frame I have. Example is: okee: Date rainfall 1997-05-01 0 1997-05-02 0 1997-05-03 NA 1997-05-04 0 1997-05-05 0 ..................... ..
2011 Jul 22
1
Plotting compound functions--help with defining x-axis as f(x)
Hi all, I'm having trouble locating a script that will allow to me to create graphs that show compound functions as a function of the simple function, rather than just x (or time as it is in my case). Currently I have the following functions defined in my script: > > > T1<-function(t) {27.5-12.5*cos(2*pi*t/365)**} > and > > B1<-function(T1,t)
2012 Nov 06
1
Filling matrix elements with a function
Hi all, I have a matrix simulating migration in a spatial model. I want to be able to define movement (the values of m1, m2 and m3) as only != 0 between adjacent patches and contingent on certain conditions as defined in the function. Here is the code: WET<-function(t) {everglades$precipitation[t]} #simply reads precipitation data from a csv, value is numeric AB<-function(WET,t)
2011 Jun 15
2
Trouble with compound functions---differential equations
Hi all, My apologies if this message is incredibly inept but I am very new to both computer programming and to R. I am working with the odesolve add-on and have the following function defined RVF_Single <- function(t, x, p) within the script I also have the following functions defined: T1<-function(t) {T1<-27.5-12.5*cos(2*pi*t/365)} and B1<-function(T1,t)
2013 Mar 13
1
saving vector output as numeric
Hi everybody, I'm trying to create a numerical data frame on which to perform PRCC. So far I have created a data frame that consists of function/vector output that displays in numerical form, but when I try and run PRCC (from epiR package) I get the following error message: "Error in solve.default(C) : Lapack routine dgesv: system is exactly singular" It appears this is because