similar to: Define a custom-built loss function and combine it with nls()

Displaying 20 results from an estimated 200 matches similar to: "Define a custom-built loss function and combine it with nls()"

2006 Nov 14
2
dividing vectors into bins with equal widths
Hi R-users, I am trying to divide a vector (say X) into equal frequency bins. If one uses the hist() function, then a histogram is plotted, but with bins of equal widths, and not with bins having the same number of data points. I have then tried the histogram() function as follows: histogram(X, nint=10, breaks=NULL, equal.widths=F) This works as I want. However, I can't extract which
2005 May 24
2
R OS X
Hi, with newest R.app (1.11) / R2.1.0a if a package is installed for the current user, it is not installed properly (does not get an installed version entry and is not loadable). If installed system wide it works. The package I installed is xgobi. MAC OS X 10.4.1 Volker - - - - - - - - - - - - - ------ ---- ---- --- -- - - - - - - - - - - - - - - -
2011 Nov 01
1
predict lmer
Dear all, I've been reading for many days trying to predict with lmer but I haven't managed to do it. I've fitted an allometric model for trees where I have included climatic variables and diameter in the fixed part and in the random part I've included the experimental sites where trees are and also their provenance region. The model is like this :
2002 Dec 11
1
residuals: lm and glm
Dear list members, I would like to know the difference in outputs and calculation processes between residuals.glm(object, type="response") and residuals.lm(object). For above-ground biomass estimation of trees, I estimated parameters of an allometric equation (ln y = b0 + b1*ln x) using glm as follows: fm <- glm(Ws~log(Wb), family=quasi(link="log",
2012 May 31
1
fitting allometric equation using a for a power model
Hello all, I'm fitting an allometric equation that looks like a really clean fit in the log-log space, but when I back transform the fit of the curve appears to need an adjustment - the fitted curve appears to predict values a good deal higher than those from the data. I included a bias correction per Newman, M. (1993). Regression analysis of log‐transformed data: Statistical bias and its
2001 Sep 12
1
nonlinear fitting when both x and y having measurement e
Sorry, for disturbing the list again. > Also I got one suggestion of using ORDPACK at http://www.netlib.org/. It's ODRPACK at http://www.netlib.org/, not ORDPACK. Best, -- Etsushi Kato ekato at ees.hokudai.ac.jp -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send
2010 Aug 04
0
nls and geometric mean regression
Hello folks, I'm seeking opinions about the validity of the following use of the nls function... A colleague and myself are working with tree allometric data consisting of measurements of individual trees in semi-arid Australian woodland species. We need to make predictions of trunk diameter (DBH: diameter at breast height) given tree height and vice versa. I _think_ this falls into the
2008 Oct 21
0
Major Axis residuals
I am having trouble extracting residuals from Major Axis and Standardized Major Axis fits, using the smatr package. I wish to understand the relationship between density of wood in twigs and trunks, and how the slope of their relationship varies among sites, among families, and with tree size. These variance-partitioning desires push the analysis toward a mixed model framework. However,
2012 May 11
0
Additional info: help with SMATR: help with pairwise comparisons using MA regression?
Also, this works (taking out multcomp=TRUE, multcompmethod="adjusted"): com.test=ma(Head.W1~Leg.3.1+Site, type="elevation", data=queens) print(com.test) ....so for some reason it will do an MA regression on all my data point together, but shows an error when I try to do pairwise comparisons between groups. Thank you, Ioulia -------- On Fri, May 11, 2012 at 2:09 AM, Ioulia
2001 Apr 05
1
No subject
R-helpers, Beginner in R language, I have a problem to install a package (multiv) in R for Windows 98 (R-Gui) First I have got the multiv.zip file from the CRAN precompiled contributed packages for Windows and put this file in C:/Program Files/rw1022. in R-Gui I tried to install it as following > install.packages("C:/Program Files/rw1022/multiv.zip") I received the following
2010 Sep 11
5
for loop
Hello, I have a simple question: I want to list numbers 1:k, but if k <1, I hope nothing listed. how should we do? k=2 for (i in 1:k)  print(i) [1] 1    # <-correct [1] 2 k=0 for (i in 1:k) print(i) [1] 1      #<---- wrong [1] 0   thanks jian [[alternative HTML version deleted]]
2011 Apr 01
1
qcc.overdispersion-test
Hi all, I have made an overdispersion test for a data set and get the following result Overdispersion test Obs.Var/Theor.Var Statistic p-value poisson data 16.24267 47444.85 0 after deleting the outliers from the data set I get the following result Overdispersion test Obs.Var/Theor.Var Statistic p-value poisson data 16.27106 0 1 The
2012 Jan 29
2
Data Structure to Code
Given: data(AirPassengers) I get a ts data structure AirPassengers in the workspace. How can I generate the code that can create that structure? That is, given an example of a data structure, is there a way to generate the code that can greate that structure? Alternatively, is there a reference that provides a list of dta structures together with a full list of theor respective attributes?
2003 Feb 20
2
is.numeric
Hi, I have a vector, which contains both strings and numbers, e.g. > foo <- c("str1",1234,"str2",0.9876) I want to know if a distinct element of the vector is a string or a number and took "is.numeric", but > is.numeric(foo[2]) [1] FALSE because R treats the numbers in a mixed vectors as strings: > foo [1] "str1" "1234"
2009 Apr 23
1
Failing to print mer object in an RData image
Hi all I have problems in accessing a mer object called model.01 from a workspace that was created with R 2.8.1 and saved with save into an .RData file (on Windows XP or Ubuntu 8.10, don't remember anymore). Now I want to open it in R 2.9.0 on Ubuntu 8.10. I use # load workspace load("name.RData") which seems to work: ls() # all objects in there [1] "all"
2011 Jan 27
1
Quasi-poisson glm and calculating a qAIC and qAICc...trying to modilfy Bolker et al. 2009 function to work for a glm model
Sorry about re-posting this, it never went out to the mailing list when I posted this to r-help forum on Nabble and was pending for a few days, now that I am subscribe to the mailing list I hope that this goes out: I've been a viewer of this forum for a while and it has helped out a lot, but this is my first time posting something. I am running glm models for richness and abundances. For
2003 Sep 26
2
checking generic/method consistency
Hi, I wrote a package for linear programming and want to submit it to CRAN. Since the package 'quadprog' has a function with the name 'solve.QP' to perform Quadratic Programming, I named my (main) function 'solve.LP'. However 'R CMD check' gives one warning: * checking generic/method consistency ... WARNING solve: function(a, b, ...) solve.LP:
2003 Oct 23
3
Writing and running a R program
Is there a way I can combine multiple lines of R commands (see below) into a little code snippet or a program in a text file, and run it in R to do my analysis? sink("mysink.txt") for (......) { code for creating a dataframe from supplied data code for doing anova from selected data } Thanks very much. Karth.
2012 May 11
0
help with SMATR: help with pairwise comparisons using MA regression?
Hi there, I've been using the SMATR package to do standardized major axis (SMA) regression on allometric data, and I've been able to to pairwise comparisons of slope & elevation between multiple study sites. Now I'm trying to do the same thing using major axis (MA) regression, but I'm getting errors (SMATR should be able to do MA as well as SMA regression for everything,
2012 Feb 12
1
how to extract p values in svyglm
summary(result) Call: svyglm(Injury ~ seat, sD, family = quasibinomial(link = "logit")) Survey design: svydesign(~1, prob = NULL, strata = Data[, 1], weights = Data[, 4], data = Data, fpc = ~fPc) Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) -4.256875 0.001421 -2996.7 <2e-16 *** seatbad 0.681504 0.001689 403.4 <2e-16 *** ---