Displaying 20 results from an estimated 4000 matches similar to: "[basic ?] Merging result of by processing with a data fra me"
2011 May 29
1
dynamic programming
Dear members of R forum,
I'm trying to perform a simply dynamic programming model in R, following the
reccomendations of Soetart & Herman (A practical guide to ecological
modeling). However, I've obtained a number of problems, that I'm unable to
solve (even thoughI've tried during at least 2 hours). Can anyone help me?
Many thanks
> ccrit <- 0
> cmax <- 5
>
2008 Sep 29
0
Script for dose proportionality assessment using power model and confidence interval criteria
Dear R-Helpers
Has anyone written a script for the dose proportionality assessement
using the power model and the confidence interval criteria as described
in
- Gough at al. Assessment of dose proportionality: report from the
statisticians in the pharmaceutical industry in Drug Information
Journal,1995, 29:1039-1048 and/or
- Smith et al. Confidence interval criteria for assessment of dose
2010 May 02
2
Calculation error
Dear Rxperts,
Running the following code:
=======================================================
twlo=10; twhi=20; wt=154; vd=0.5; cl=0.046; tau=6; t=3; F=1;
wtkg <- wt/2.2 # convert lbs to kg
vd.pt <- wtkg * vd # compute weight-based vd (L)
cl.pt <- wtkg * cl # compute CL (L/hr)
k <- cl.pt/vd.pt # compute k (hr^-1)
cave <-
2016 Feb 10
0
Method from package dependency is not updated due to lazy load?
Hi,
not sure this is a bug or just an unavoidable undesirable side-effect -- or
just me that does not do the right thing.
Consider the code and output below. It creates 2 packages:
* pkgA
* pkgB that creates a method for a generic defined in pkgA
Changes in a method for the generic in pkgA (after re-installing pkgA) are
not reflected in pkgB, unless pkgB is re-installed against the new
2008 Jul 28
2
Help with a loop
HI:
I need ideas on how to make this code shorter (maybe with a second loop?).
The code as it is works, but in this case I only have 14 samples, but it
will become insane with more, so I need a way to make it more automatic. The
problem is that the output from ts1, ts2, and so on is a vector with more
than one value, so I do not know how to solve this.
Thanks
Prenewbie
The code is the
2010 Sep 07
0
Sexpr in package.Rd fails
If I
f = function() {}
package.skeleton("PkgA", "f", path="/tmp")
and then edit man/PkgA-pacakge.Rd to read in part
\description{
More about what it does (maybe more than one line)
\Sexpr{1}
}
and then
R CMD build PkgA
I end up with
Saving output to ?/tmp/PkgA/build/PkgA.pdf? ...
Warning in file.create(to[okay]) :
cannot create file
2011 Jun 17
0
Inconsistent results from var.get.nc in RNetCDF
Hello -
I am having trouble extracting data from NetCDF data files using
RNetCDF. The data files each have 3 dimensions (longitude, latitude,
and a date) and 3 variables (latitude, longitude, and a climate
variable).
Here is some of the output from print.nc for clarity:
-----
dimensions:
month = UNLIMITED ; // (1368 currently)
lat = 3105 ;
lon = 7025 ;
variables:
float
2015 Jul 03
1
Are downstream dependencies rebuilt when a package is updated on CRAN?
I was wondering: are the downstream dependencies of a package rebuilt
when a package is updated on CRAN? (I'm referring to the binary
packages, of course.)
The reason I ask is because there are cases where this can cause
problems. Suppose that when pkgB is built, it calls
pkgA::makeClosure(), which returns a closure that refers to a function
in pkgA. Suppose this code is in pkgA 1.0:
2013 Aug 30
2
"False" warning on "replacing previous import" when re-exporting identical object
Hi,
SETUP:
Consider three packages PkgA, PkgB and PkgC.
PkgA defines a generic function foo() and exports it;
export(foo)
PkgB imports PkgA::foo() and re-exports it;
importFrom(PkgA, foo)
export(foo)
PkgC imports everything from PkgA and PkgB:
imports(PkgA, PkgB)
PROBLEM:
Loading or attaching the namespace of PkgC will generate a warning:
replacing previous import by
2014 Feb 21
0
instantiating a reference class with an initialize() method from .onLoad fails
PkgA has a single R/binding.R file containing
.A <- setRefClass("A", methods=list(initialize=function(...) {}))
.onLoad <- function(...) .A()
A NAMESPACE with
import(methods)
exportClasses("A")
and DESCRIPTION
Package: PkgA
Type: Package
Title: Documenting reference classes
Version: 0.0.1
Date: 2012-08-05
Author: Martin
2013 Feb 04
1
ggplot and colors
Hello,
I have a problem with ggplot and colors
I used this function to draw somes lines and I want them to be all black
(just to test)
however, I dont get any black line in the figure.
Do you have any experience with ggplot and manual colors??
ggplot(cmax, aes(cmax[,3], cmax[,6],colour=interaction(cmax[,1],cmax[,2])))
+ geom_line() + geom_point() +
2014 Oct 31
2
Options that are local to the package that sets them
Dear All,
I am trying to do the following, and could use some hints.
Suppose I have a package called pkgA. pkgA exposes an API that
includes setting some options, e.g. pkgA works with color palettes,
and the user of the package can define new palettes. pkgA provides an
API to manipulate these palettes, including defining them.
pkgA is intended to be used in other packages, e.g. in pkgB1 and
2015 May 12
1
S4 method dispatch sometimes leads to incorrect when object loaded from file?
>>>>> Martin Morgan <mtmorgan at fredhutch.org>
>>>>> on Mon, 11 May 2015 10:18:07 -0700 writes:
> On 05/10/2015 08:19 AM, Martin Morgan wrote:
>> Loading an S4 object from a file without first loading the library sometimes (?,
>> the example below and actual example involves a virtual base class and the show
>> generic)
2011 Aug 08
0
Re: Tmax Window(a propietary OS) using Wine?
Forgive my poor English.
There is Tmax Window, the 1st windows XP compatible proprietary OS from Korea.
Tmax company showed screenshot of Tmax Windows.
But it is known as they mixed images with real XP and OpenOffice suite screenshots.
http://mr-dust.pe.kr/entry/Tmaxwindow-screenshot-failed
Tmax Window is doubtful about stolen ReactOS source code:
This is a post of a tmax developer.
2015 May 11
0
S4 method dispatch sometimes leads to incorrect when object loaded from file?
On 05/10/2015 08:19 AM, Martin Morgan wrote:
> Loading an S4 object from a file without first loading the library sometimes (?,
> the example below and actual example involves a virtual base class and the show
> generic) leads to incorrect dispatch (to the base class method).
>
> The attached package reproduces the problem. It has
The package was attached but stripped; a version is
2007 Oct 25
0
Error message from nlmer
Hi,
I have R 2.6.0 with updated lme4 and Matrix packages, and I am trying to
fit a nonlinear multilevel model. I get the following error message:
Error in nlmer(f ~ grModel(x, w, Tmin, Tmax, Topt, kopt, m) ~ kopt |
flat, :
gradient attribute of evaluated model must be a numeric matrix
and I wonder what this may indicate.
The nonlinear model I try to fit is as follows:
> grModel
2013 Apr 24
0
Understanding how nls() works
I'm trying to understand what goes on in the process that nls() uses.
This converges without much drama:
> rate.nls <- nls(Dev ~ exp(rho * (T)) - exp(rho*Tmax - (Tmax - T)/del)+
+ lam , data = xx, trace = TRUE,
+ start = c(rho = 0.15, del = 7, lam = .02, Tmax = 30))
599.7841 : 0.15 7.00 0.02 30.00
4.69849 : 0.14673457 6.83443060 -0.01417782
2011 Dec 13
1
tcplot documentation in evd package
Hello, and please advise regarding any errors/omissions on my part.
However, the documentation for R's tcplot function in the evd package
appears to contain an error. I am using evd version 2.2-4 in R 2.14.0
with Windows XP.
> data(portpirie)
> mrlplot(portpirie) ## No Error
> tlim <- c(3.6, 4.2)
> tcplot(portpirie, tlim) ## Line from documentation
Error in fpot(data, u[1],
2009 Aug 17
2
S4 Generics and NAMESPACE : justified warning ?
Dear list,
It seems that a package (pkgB) using another package (pkgA) with S4
generics formed by taking existing functions (for example 'plot') must
not import the existing functions ('plot') in its namespace to avoid
the warning "replacing previous import: plot".
Suppose we use the simple 'import' directive in the name space of
pkgB.
pkgA and pkgB files would
2012 Feb 26
1
improved error message when existing implicit S4 generic is not imported?
pkgA's NAMESPACE has
importFrom(graphics, plot)
exportClasses("A")
exportMethods("plot")
R/foo.R has
setClass("A")
setMethod("plot", "A", function(x, y, ...) {})
During R CMD INSTALL pkgA_1.0.tar.gz we are told
** preparing package for lazy loading
Creating a generic function for 'plot' from package