search for: terms

Displaying 20 results from an estimated 23962 matches for "terms".

2001 Jun 06
1
ppr, number of terms, and data ordering
...ion is: is there a recommended way to sort the data before running ppr? In the meantime, I'll try sorting by my two continuous RHS variables to see if it makes a difference -- not a definitive answer but it may be suggestive. My second question is: is my method for deciding on the number of terms in the regression okay? What I am doing is first running ppr with a large maximum number of terms, then finding the number of terms that minimizes the goodness-of-fit statistic. Looking at the cpus example in the section of MASS that deals with ppr (pp. 293-294), it is unclear why eight terms wer...
2004 Mar 18
1
termplot has problems with a single term (fix included) (PR#6675)
The bug exists on R-1.9.0-alpha compiled the 10/3. Termplot has a problem if either the model only contains a single term or if asked to plot a single term. In addition there are problems with the option se = TRUE. Analysis: termplot starts with terms <- if (is.null(terms)) predict(model, type = "terms", se = se) else predict(model, type = "terms", se = se, terms = terms) n.tms <- ncol(tms <- as.matrix(if (se) terms$fit else terms)) In this case terms is now a matrix of f...
2006 May 23
5
AR Caching and Reflection
When I do this: term = Term.find(1, :include => :definition) term.definition.term Two SQL queries are fired, why? -- Posted via http://www.ruby-forum.com/.
2006 Oct 05
4
search results autocompletion
Dear list, I ''m using a text input field with autocompletion . The suggestions come from a ferret index which is created by getting all the terms belonging to other indices. Here is the code: class Suggestion attr_accessor :term def self.index(create) [Person, Project, Orgunit].each{|kl| terms = self.all_terms(kl) terms.each{|term| suggestion = Suggestion.new suggestion.term = term SUGGESTION_I...
2004 Mar 31
6
Can't compile asterisk.
hi. I got these compile errors while install asterisk. readline and openssl are compiled using gnu source, and kernel version is 2.4.17. Compile errors message is follows. Someone cleared this problem? Please, help! Regards. ---------------------------------------------------------------------------------- gcc -g -o asterisk -Wl,-E io.o sched.o logger.o frame.o loader.o config. o channel.o
2010 Aug 03
5
grep with search terms defined by a variable
...a search term that is stored in a variable when the search string is more complex. #Say I have a string, and want to know whether the last name "Jannings" is in the string. This is done by names=c("Emil Jannings") grep("Emil",names) #Yet, I need to store the search terms in a variable, which works for the very simple example search.term="Emil" grep(search.term,names) #but I cannot get it to work for the more difficult example in which I want to do something like grep(^search.term,names) grep("^search.term",names) grep("^"search.term...
2009 Feb 24
1
odfWeave problem "Error in xmlEventParse"
Dear list, Sorry for bothering you with a pure odfSweave question, but I just ran into a problem that I cannot find the cause of. Anyonse seen this before? This file "used to work", but not anymore. Would apreciate all the help I could get. /Fredrik --------------------------------------------------------------- >
2004 Mar 18
1
termplot has problems with a single term (fix included) (PR#6679)
...oblem if either the model only contains a single term > or if asked to plot a single term. In addition there are problems with > the option se = TRUE. I can't reproduce this in either R-devel or 1.8.1, and termplot hasn't changed since January. I do example(termplot) termplot(model, terms="z") termplot(model, terms="z", se=TRUE) termplot(model, terms=1) termplot(model, terms="ns(x, 6)") termplot(model, terms="ns(x, 6)", se=TRUE) termplot(model, terms=2) mm<-glm(y~x) termplot(mm) termplot(mm,se=TRUE) mm<-glm(y~x-1) termplot(mm) termplot(...
2018 Mar 08
4
Fwd: Re: [EXTERNAL] Re: backquotes and term.labels
Ben, Looking at your notes, it appears that your solution is to write your own terms() function for lme.? It is easy to verify that the "varnames.fixed" attribute is not returned by the ususal terms function. Then I also need to write my own terms function for the survival and coxme pacakges? Because of the need to treat strata() terms in a special way I manipulate the f...
2018 Mar 05
2
backquotes and term.labels
...iff(Surv(time, status) ~ `in st`, data=lung2) Error in `[.data.frame`(m, ll) : undefined columns selected In the body of the code the program want to send all of the right-hand side variables forward to the strata() function.? The code looks more or less like this, where m is the model frame ? Terms <- terms(m) ? index <- attr(Terms, "term.labels") ? if (length(index) ==0)? X <- rep(1L, n)? # no coariates ? else X <- strata(m[index]) For the variable with a space in the name the term.label is "`in st`", and the subscript fails. Is this intended behaviour o...
2012 Aug 31
2
[PATCH] Add missing options to flac man page.
--- man/flac.1 | 25 +++++++++++++++++++++---- man/flac.sgml | 2 ++ 2 files changed, 23 insertions(+), 4 deletions(-) diff --git a/man/flac.1 b/man/flac.1 index fef4ded..3d7bd50 100644 --- a/man/flac.1 +++ b/man/flac.1 @@ -68,6 +68,9 @@ Prefix each output file name with the given string. This can be useful for enco \fB--delete-input-file \fR Automatically delete the input file after
2018 Mar 07
1
backquotes and term.labels
Thanks to Bill Dunlap for the clarification. On follow-up it turns out that this will be an issue for many if not most of the routines in the survival package: a lot of them look at the terms structure and make use of the dimnames of attr(terms, 'factors'), which also keeps the unneeded backquotes. Others use the term.labels attribute. To dodge this I will need to create a fixterms() routine which I call at the top of every single routine in the library. Is there a chance...
2018 Mar 08
1
Fwd: Re: [EXTERNAL] Re: backquotes and term.labels
>>>>> Ben Bolker <bbolker at gmail.com> >>>>> on Thu, 8 Mar 2018 09:42:40 -0500 writes: > Meant to respond to this but forgot. > I didn't write a new terms() function -- I added an attribute to the > terms() (a vector of the names > of the constructed model matrix), thus preserving the information at > the point when it was available. > I do agree that it would be preferable to have an upstream fix ... did anybody ever pr...
2010 Jan 16
1
PHP XapianTermIterator/XapianPositionIterator usage
...is to code up a test case in PHP to perform snippet extraction (with a possible view to coding a pecl extension in C). I found a C++ sample, but that wasn't much help. I must be dense this morning though, since I can't get my head around how to use XapianTermIterator to step through the terms, and to iterate through all the positions of each term with XapianPositionIterator. Can someone provide a basic PHP example of how to: //pseudo code $position_iterator = new XapianPositionIterator(); $term_iterator = new XapianTermIterator(); foreach $term ($position_iterator) foreach $p...
2008 Mar 30
1
Second & subsequent calls to function fails. Please help debug.
...: { envir <- environment(formula(m)) dd <- eval(m$call$data, envir) subs <- eval(m$call$subset, envir) wgts <- eval(m$call$weights, envir) naa <- m$call$na.action dd <- data.frame(dd, preds.sq = predict(m, dd)^2) uf <- update.formula(formula(m$terms), ~. + preds.sq) environment(uf) <- environment(NULL) mup <- if (is.null(naa)) lm(uf, data = dd, subset = subs, weights = wgts) else lm(uf, data = dd, subset = subs, weights = wgts, na.action = naa) if (mup$rank > m$rank) { ans <- summary(mup)$coe...
2017 Mar 10
2
named arguments in formula and terms
Hi, we came across the following unexpected (for us) behavior in terms.formula: When determining whether a term is duplicated, only the order of the arguments in function calls seems to be checked but not their names. Thus the terms f(x, a = z) and f(x, b = z) are deemed to be duplicated and one of the terms is thus dropped. R> attr(terms(y ~ f(x, a = z) + f(x,...
2015 Jun 15
2
Different behavior of model.matrix between R 3.2 and R3.1.1
Terry - your example didn't demonstrate the problem because the variable that interacted with strata (zed) was not a factor variable. But I had stated the problem incorrectly. It's not that there are too many strata terms; there are too many non-strata terms when the variable interacting with the stratification factor is a factor variable. Here is a simple example, where I have attached no packages other than the basic startup packages. strat <- function(x) x d <- expand.grid(a=c('a1','a2'...
2015 Jun 15
2
Different behavior of model.matrix between R 3.2 and R3.1.1
Terry - your example didn't demonstrate the problem because the variable that interacted with strata (zed) was not a factor variable. But I had stated the problem incorrectly. It's not that there are too many strata terms; there are too many non-strata terms when the variable interacting with the stratification factor is a factor variable. Here is a simple example, where I have attached no packages other than the basic startup packages. strat <- function(x) x d <- expand.grid(a=c('a1','a2'...
2004 Dec 13
3
Advice on parsing formulae
Dear list I would like to be able to group terms in a formula using a function that I will call tvar(), eg. the formula Y ~ 1 + tvar(x:A) + tvar(z) + u + tvar(B) + tvar(poly(v,3)) where x,u and v are numeric and A and B are factors - binary, say. As output, I want the model.matrix as if tvar had not been there at all. In addition, I would like...
2005 Jul 08
4
Sweave resource leak: leftover temp files (PR#7998)
Harold, I've taken a closer look at your example and I'd call this an Sweave bug. It creates tempfiles each time you run it, and doesn't delete them at the end. For example: > list.files(tempdir()) character(0) > testfile <- system.file("Sweave", "Sweave-test-1.Rnw", package = "utils") > Sweave(testfile, out="junk.tex")