similar to: question about masking

Displaying 20 results from an estimated 10000 matches similar to: "question about masking"

2007 Jun 22
1
two basic question regarding model selection in GAM
Qusetion #1 ********* Model selection in GAM can be done by using: 1. step.gam {gam} : A directional stepwise search 2. gam {mgcv} : Smoothness estimation using GCV or UBRE/AIC criterion Suppose my model starts with a additive model (linear part + spline part). Using gam() {mgcv} i got estimated degrees of freedom(edf) for the smoothing splines. Now I want to use the functional form of my model
2006 Sep 05
3
terms.inner
Question: I am trying to impliment a function in R that we use quite regularly in Splus, and it fails due to a lack of the "terms.inner" function in R. The substitute is? Part question and part soapbox: Why remove terms.inner from R? It's little used, but rather innocuous. Mostly soapbox: I figured it was no big deal, as I originally discovered the use of terms.inner from
2003 May 22
3
How to avoid function masking
Hi All, I've been working on updating the 'genetics' package. As a consequence of the upgrade, .First.lib() looks like: .First.lib <- function(libname, pkgname) { if (!require(combinat)) warning("Unable to load 'combinat' library. Function `diseq.ci' will fail.") require(gregmisc) genotype <-
2005 Mar 24
1
Prediction using GAM
Recently I was using GAM and couldn't help noticing the following incoherence in prediction: > data(gam.data) > data(gam.newdata) > gam.object <- gam(y ~ s(x,6) + z, data=gam.data) > predict(gam.object)[1] 1 0.8017407 > predict(gam.object,data.frame(x=gam.data$x[1],z=gam.data$z[1])) 1 0.1668452 I would expect that using two types of predict arguments
2013 Jul 08
1
error in "predict.gam" used with "bam"
Hello everyone. I am doing a logistic gam (package mgcv) on a pretty large dataframe (130.000 cases with 100 variables). Because of that, the gam is fitted on a random subset of 10000. Now when I want to predict the values for the rest of the data, I get the following error: > gam.basis_alleakti.1.pr=predict(gam.basis_alleakti.1, +
2010 Dec 14
2
Use generalised additive model to plot curve
Readers, I have been reading 'the r book' by Crawley and think that the generalised additive model is appropriate for this problem. The package 'gam' was installed using the command (as root) install.package("gam") ... library(gam) > library(gam) Loading required package: splines Loading required package: akima > library(mgcv) This is mgcv 1.3-25 Attaching
2004 Aug 06
2
gam --- a new contributed package
I have contributed a "gam" library to CRAN, which implements "Generalized Additive Models". This implementation follows closely the description in the GAM chapter 7 of the "white" book "Statistical Models in S" (Chambers & Hastie (eds), 1992, Wadsworth), as well as the philosophy in "Generalized Additive Models" (Hastie & Tibshirani 1990,
2004 Aug 06
2
gam --- a new contributed package
I have contributed a "gam" library to CRAN, which implements "Generalized Additive Models". This implementation follows closely the description in the GAM chapter 7 of the "white" book "Statistical Models in S" (Chambers & Hastie (eds), 1992, Wadsworth), as well as the philosophy in "Generalized Additive Models" (Hastie & Tibshirani 1990,
2007 Apr 08
1
Relative GCV - poisson and negbin GAMs (mgcv)
I am using gam in mgcv (1.3-22) and trying to use gcv to help with model selection. However, I'm a little confused by the process of assessing GCV scores based on their magnitude (or on relative changes in magnitude). Differences in GCV scores often seem "obvious" with my poisson gams but with negative binomial, the decision seems less clear. My data represent a similar pattern as
2008 Aug 03
1
output components of GAM
I would like to request help with the following: I am trying to use a Generalized Additive Model (gam) to examine the density distribution of fish as a function of latitude and longitude as continuous variables, and year as a categorical variable. The model is written as:   gam.out   <-  gam(Density ~ s(Lat) + s(Lon) + as.factor(Year))   The fitted model prediction of the link function is
2007 Oct 05
2
question about predict.gam
I'm fitting a Poisson gam model, say model<-gam(a65tm~as.factor(day.week )+as.factor(week)+offset(log(pop65))+s(time,k=10,bs="cr",fx=FALSE,by=NA,m=1),sp=c( 0.001),data=dati1,family=poisson) Currently I've difficulties in obtaining right predictions by using gam.predict function with MGCV package in R version 2.2.1 (see below my syntax).
2012 Feb 17
1
Standard errors from predict.gam versus predict.lm
I've got a small problem. I have some observational data (environmental samples: abiotic explanatory variable and biological response) to which I've fitted both a multiple linear regression model and also a gam (mgcv) using smooths for each term. The gam clearly fits far better than the lm model based on AIC (difference in AIC ~ 8), in addition the adjusted R squared for the gam is
2011 Jun 20
3
About GAM in R, Need YOUR HELP!
I'm beginner in R! I have a lot of problems on R..... I have three questions about GAM 1. What is the function of Gaussian distribution in GAM?(if I choose family is Gaussian) Is it used in the predictand value (Y)? 2. How to plot a graph the gam function? For example: y<-gam(a~s(b),family=gaussian (link=log) ,Data) how to plot x axis is s(b) and y axis is log a??? 3. if I use GAM to
2010 Jan 26
1
AIC for comparing GLM(M) with (GAM(M)
Hello I'm analyzing a dichotomous dependent variable (dv) with more than 100 measurements (within-subjects variable: hours24) per subject and more than 100 subjects. The high number of measurements allows me to model more complex temporal trends. I would like to compare different models using GLM, GLMM, GAM and GAMM, basically do demonstrate the added value of GAMs/GAMMs relative to
2010 Jun 27
1
mgcv out of memory
Hello, I am trying to update the mgcv package on my Linux box and I keep getting an "Out of memory!" error. Does anyone know of a fix for this? Below is a snippet of the message that I keep getting: Thank you. Geoff ** R ** inst ** preparing package for lazy loading ** help *** installing help indices >>> Building/Updating help pages for package 'mgcv' Formats:
2012 Jul 30
1
te( ) interactions and AIC model selection with GAM
Hello R users, I'm working with a time-series of several years and to analyze it, I?m using GAM smoothers from the package mgcv. I?m constructing models where zooplankton biomass (bm) is the dependent variable and the continuous explanatory variables are: -time in Julian days (t), to creat a long-term linear trend -Julian days of the year (t_year) to create an annual cycle - Mean temperature
2005 Oct 05
3
testing non-linear component in mgcv:gam
Hi, I need further help with my GAMs. Most models I test are very obviously non-linear. Yet, to be on the safe side, I report the significance of the smooth (default output of mgcv's summary.gam) and confirm it deviates significantly from linearity. I do the latter by fitting a second model where the same predictor is entered without the s(), and then use anova.gam to compare the
2005 Sep 26
4
p-level in packages mgcv and gam
Hi, I am fairly new to GAM and started using package mgcv. I like the fact that optimal smoothing is automatically used (i.e. df are not determined a priori but calculated by the gam procedure). But the mgcv manual warns that p-level for the smooth can be underestimated when df are estimated by the model. Most of the time my p-levels are so small that even doubling them would not result
2008 Nov 15
1
GAMs and GAMMS with correlated acoustic data
Greetings This is a long email. I'm struggling with a data set comprising 2,278 hydroacoustic estimates of fish biomass density made along line transects in two lakes (lakes Michigan and Huron, three years in each lake). The data represent lakewide surveys in each year and each data point represents the estimate for a horizontal interval 1 km in length. I'm interested in comparing
2005 Oct 12
1
step.gam and number of tested smooth functions
Hi, I'm working with step.gam in gam package. I'm interested both in spline and lowess functions and when I define all the models that I'm interested in I get something like that: > gam.object.ALC<-gam(X143S~ALC,data=dane,family=binomial) >