Displaying 20 results from an estimated 400 matches similar to: "Help with functions"
2008 Oct 23
3
Fuctions help!
Hi everyone,
I have a question about functions. I have two functions:
Sampling=function(fname,Total,nSample,nPatient){......return(list(Gmean,Gsd))}
Power=function(alfa,m1,m2,s1,s2,n1,n2){....return(powe)}
I want to use "Gmean" and "Gsd" which are the returned values from
"Sampling" function, in "Power" function.
i.e. when I call "power" I want
2008 Oct 17
2
function help
Hi everyone,
I have dataset which I make a sample of it couple of times and each time I
get the mean and standard deviation of each row for each sample. I have a
function for that, which takes the name of the file and number of times to
sample and then returns the mean and standard deviation for each row in each
sample.
Sample=function(name, n){
2010 Jan 26
3
Problem with "nls" function
Dear R users,
I have a response variable in a csv file called "y" and a matrix of
predictor variables in a csv file called "mat". I have used the function
"nls" I have specified the nonlinear relation between these variable.The
code I have witten is called Rprog which begins with the phrase:
L.minor.m1<-nls(Y~a ....etc..
The program when I execute the program, I
2012 May 13
1
userdb namespace settings bug
Hi!
Since upgrading to 2.1.6, setting namespaces via environment variables
using a imap-postlogin-script *sometimes* doesn't work.
Sometimes, the prefix of a namespace isn't set correctly, but is set to
an empty string, which leads to the following error:
namespace configuration error: Duplicate namespace prefix: ""
However, the environment is set correctly, the error seems to
2004 Oct 29
1
fitting linear mixed model for incomplete block design
Dear R developers and users:
I have the following data, x is the response vaiable, nsample(individual) nested within trt, and subsample nested within nsample, I want to fit trt as fixed effect, and block, nsample(trt) as random effects using lme, is the following coding correct?
dat$vgrp <- getGroups(dat, form = ~ 1|trt/nsample, level = 2)
ge.lme1 <- lme(fixed=x~trt, data=dat,
2013 Apr 17
1
mgcv: how select significant predictor vars when using gam(...select=TRUE) using automatic optimization
I have 11 possible predictor variables and use them to model quite a few
target variables.
In search for a consistent manner and possibly non-manual manner to identify
the significant predictor vars out of the eleven I thought the option
"select=T" might do.
Example: (here only 4 pedictors)
first is vanilla with "select=F"
>
2015 May 18
1
Getent group don't work
Hi
Oracle Linux Server client with Samba 3.6.23 (file server) joined to the
Samba4 AD domain.
----------------
smb.conf
[global]
#--authconfig--start-line--
netbios name = FS
server string = "GSDAD Fileserver"
workgroup = GSDAD
realm = AD.GSD.LAN
security = ads
winbind use default domain = yes
idmap config * : backend = rid
idmap config * : range =
2012 Mar 27
4
Help on predict.lm
Hello,
I'm new here, but will try to be as specific and complete as possible. I'm
trying to use “lm“ to first estimate parameter values from a set of
calibration measurements, and then later to use those estimates to calculate
another set of values with “predict.lm”.
First I have a calibration dataset of absorbance values measured from
standard solutions with known concentration of
2011 May 16
1
Matrix manipulation in for loop
Hi all,
I have a problem with getting my code to do what I want!
This is the code I have:
create.means.one.size<-function(nsample,var,nboot){
mat.x<-matrix(0,nrow=nboot,ncol=nsample)
for(i in 1:nboot){
mat.x[i,]<-sample(var,nsample,replace=T)
}
mean.mat<-rep(0,nboot)
for(i in 1:nboot){
mean.mat[i]<-mean(mat.x[i,])
}
sd.mean<-sd(mean.mat)
return(mean.mat)
}
where
2004 Sep 22
1
Sample without replacement
Hello, I have a simple problem (checked the archives and the appropriate
help pages, to no avail). I want to creat a vector that is length(2000).
The vector is to consist of two strings( "std" and "dev") with 1760 "std"s
and 240 "dev"s. Furthermore, for each element of the vector, i want the
selection of one of the strings to be approx. random. The
2005 Nov 04
1
small bug in gl1ce, package lasso2 (PR#8280)
Full_Name: Grant Izmirlian
Version: 2.2.0
OS: SuSe Linux version 9.2
Submission from: (NULL) (156.40.34.177)
Sorry about the last submission, my bug-fix had an error in it because ifelse
doesn't vectorize. I'll repost with the correct bug-fix.
-------------------------------------------------------------------------------
The option exists to include all parameters, including the
2010 Aug 17
2
AIC in MuMIn
Hello,
I am using package MuMIn to calculate AIC for a full model with 10
explanatory variables.
Thanks in advance in sharing your experience.
Q1
In the AIC list of all models, each model is differentiated by model number.
Please kindly advise if it is possible to
find the corresponding explanatory variable(s) for the model number.
Q2 error message
I tried to display sub-model with only
2003 Oct 11
2
Samba 3.0 stable: make --with-afs fails on SuSE 8.2
Hi All-
I have SuSE 8.2 installed on two different Intel machines, with (as far as
I can determine) all required packages for doing what I'm trying to do
here. Both machines suffer the same problems.
I didn't find any SuSE 8.2 rpms, so I'm trying to build Samba 3.0 (stable)
(24th Sep, 2003) on either of these machines but am having problems with
it.
As root, I did a
2019 Jun 07
2
Gnome annoyances
How do I disable /usr/libexec/gsd-backlight-helper on a user's
WORKSTATION? This is clearly something that should NEVER, EVER be running
if it's not a laptop....
mark
2004 Feb 05
2
Histograms by two factors
Hi
I am trying to print out means, STDs and histograms under two sets of factors. I can manage it for one set - see below but not for two sets. That is, I want ot print out the mean STD and Histogram for each ITEM code within each DELIVERABLE code. In addition I can only get to view the histogram for the last item. How do you get R to stop overriding the histogram for eg level 1 for factor 1
2006 Dec 11
2
updating rgl on debian stable
Running: R Version 2.3.1 (2006-06-01), debian stable
I'm testing an application that uses rgl (installed with apt-get install
r-cran-rgl)
but fails, at least partly because that application uses a more current
version.
There is also a mysterious error msg from Xlib:
> library(car)
> library(rgl)
> iris.mod <- lm(cbind(Sepal.Length, Sepal.Width, Petal.Length,
Petal.Width) ~
2014 Oct 15
0
permissions when moving mails
Hi!
I am using Unix groups to control access to shared mailboxes.
This works fine as long as files are not moved between mailboxes that
are owned by different groups. The move operation doesn't change group
ownership of the mail.
Is there a way to force dovecot to e.g. inherit the ownership from the
parent folder, not only for new messages bot also for messages moved
from one folder to
2024 Aug 11
1
Printing
Hi
In the following codes, I had to choose between printing (= TRUE) or
deliver something for grab (ei, vi). Is there a way to get both--that
is, to print and also have ei and vi for grab? Thanks.
Steven
...
out<-round(as.data.frame(cbind(ap,se,t,p)),digits)
out<-cbind(out,sig)
out<-out[!grepl(colnames(zx)[1],rownames(out)),]
if(printing){
cat("\nAPPs of bivariate ordered
2009 Aug 22
1
Why is R so slow at plotting on Ubuntu 9.04?
under Ubuntu 9.04 R seems to be very slow at plotting.
the example below illustrates with a plot of error bars of sample means
where i watch as each error bar is plotted one at a time. very annoying and pain in the neck when running Sweave repeatedly.
running R 2.9.1 under Windoze on the same machine the error bars plotted in the code below appear instantaneously.
has anyone else noticed this
2016 Apr 22
0
R2BayesX help
Hi,
I wonder if anyone can help me with this issue. I am using R2BayesX. It
seems that the model can maximally contain 20 interactions. When the number
of interaction terms exceed 20, the code stops working. Here is a piece of
toy code.
rm(list=ls())
library(BayesX)
library(R2BayesX)
#data generating model
f2<-function(x1,x2,x3,x4)
{
y<-2*sin(pi*x1)*1.5+exp(2*x2)/3+2 * sin(4 * pi * (x3