similar to: Multiplication (PR#8466)

Displaying 20 results from an estimated 9000 matches similar to: "Multiplication (PR#8466)"

2010 Sep 27
1
Split-split plot design with aov function in R
*Hello, I'm new to R and trying to do Split Split Plot Design analysis with aov function in R. Sharing any worked example and suggestion will be highly appreciated. Thanks Regards! * -- * Muhammad Yaseen * [[alternative HTML version deleted]]
2002 Aug 08
1
The unary - operator and matrix column labels
I am making some changes to the permax library (so that it will accept NA's). This function performs a permutation analysis to identify discriminating attributes distinguishing two groups of observations. It takes the form (at its most simplistic): permax(data, ig1) where ig1 is one group of interest. The other group (if not specified) is assumed to be the remaining observations, namely,
2008 Jan 27
2
Likelihood optimization numerically
Dear List, I am not sure how should i optimize a log-likelihood numerically: Here is a Text book example from Statistical Inference by George Casella, 2nd Edition Casella and Berger, Roger L. Berger (2002, pp. 355, ex. 7.4 # 7.2.b): data = x = c(20.0, 23.9, 20.9, 23.8, 25.0, 24.0, 21.7, 23.8, 22.8, 23.1, 23.1, 23.5, 23.0, 23.0) n <- length(x) # likelihood from a 2 parameter Gamma(alpha,
2002 Aug 01
4
What does persp() return?
I want to plot some 3D points on top of the grid produced by persp(). On 2/22/01, Paul Murrell <paul at stat.auckland.ac.nz> wrote in R-help: > In S-Plus, persp() returns a value that can be used to transform 3D > locations to 2D, but this sort of thing is not (yet) available in R. But persp() does return something (in R-1.5.1): a 4x4 matrix which in the C code is called the
2003 Oct 20
3
R - S compatibility table
Hello all - I've just recently been exploring R for the first time. After noticing a few things that have changed from S to R, I started looking for an R-S compatibility table but didn't find it. Is such a table out there ? Where ? Thanks much, Purvis Bedenbaugh purvis at mbi.ufl.edu Examples: 'stdev' is now 'sd' - is it exactly the same computation ? couldn't find
2005 Sep 23
4
books about MCMC to use MCMC R packages?
Dear list users, I need to learn about MCMC methods, and since there are several packages in R that deal with this subject, I want to use them. I want to buy a book (or more than one, if necessary) that satisfies the following requirements: - it teaches well MCMC methods; - it is easy to implement numerically the ideas of the book, and notation and concepts are similar to the corresponding R
2009 Dec 12
1
cube root on array
Dear R developers, is that right? > -27^(1/3) [1] -3 > c(-27,27)^(1/3) [1] NaN 3 i'm using sign( c(-27,27) ) * abs( c(-27,27)) ^(1/3) , thanks [[alternative HTML version deleted]]
2007 May 07
3
like apply(x,1,sum), but using multiplication?
Hi, I need to multiply all columns in a matrix so something like apply(x,2,sum), but using multiplication should do. I have tried apply(x,2,"*") I know this must be trivial, but I get: Error in FUN(newX[, i], ...) : invalid unary operator The help for apply states that unary operators must be quoted. I tried single quotes too, with the same results. Thanks, -Jose -- Jose
2017 Mar 17
3
Support for user defined unary functions
I agree there is no reason they _need_ to be the same precedence, but I think SPECIALS are already have the proper precedence for both unary and binary calls. Namely higher than all the binary operators (except for `:`), but lower than the other unary operators. Even if we gave unary specials their own precedence I think it would end up in the same place. `%l%` <- function(x) tail(x, n =
2017 Mar 16
2
Support for user defined unary functions
I guess this would establish a separate "namespace" of symbolic prefix operators, %*% being an example in the infix case. So you could have stuff like %?%, but for non-symbolic (spelled out stuff like %foo%), it's hard to see the advantage vs. foo(x). Those examples you mention should probably be addressed (eventually) in the core language, and it looks like people are already able
2005 May 31
4
minus: operator and sign (PR#7908)
Full_Name: Allan Sims Version: 2.1.0 OS: WinXP Submission from: (NULL) (193.40.25.254) This should not be correct. It seams that first power is applied and then sign. > -2^2 [1] -4
2006 Feb 22
4
exponent confusion
please excuse me if this ones a basic error > y<-c(-0.7,-0.6,-0.5) > -0.7^1.22 [1] -0.6471718 > y^1.22 [1] NaN NaN NaN am I missing something important in my basic math?
2017 Mar 17
2
Support for user defined unary functions
>After off list discussions with Jonathan Carrol and with >Michael Lawrence I think it's doable, unambiguous, >and even imo pretty intuitive for an "unquote" operator. For those of us who are not CS/Lisp mavens, what is an "unquote" operator? Can you expression quoting and unquoting in R syntax and show a few examples where is is useful, intuitive, and fits in to
2002 Oct 21
2
3-D scatter plot laid over Surface plot
Hello, I have created a Fitness surface (persp()), with data that was created by a tp spline procedure. Now I would like to superimpose a set (XYZ) of existing points (from two different treatments) onto this surface. I didn't come across any function or command that is able to do this in R. Could somebody please help me in finding a solution to this problem Thank you Peter --
2017 Mar 17
2
Support for user defined unary functions
Your example x = 5 exp = parse(text="f(uq(x)) + y +z") # expression: f(uq(x)) +y + z do_unquote(expr) # -> the language object f(5) + y + z could be done with the following wrapper for bquote my_do_unquote <- function(language, envir = parent.frame()) { if (is.expression(language)) { # bquote does not go into expressions, only calls
2017 Mar 17
2
Support for user defined unary functions
The unquoting discussion is IMHO separate from this proposal and as you noted probably better served by a native operator with different precedence. I think the main benefit to providing user defined prefix operators is it allows package authors to experiment with operator ideas and gauge community interest. The current situation means any novel unary semantics either need to co-opt existing
2014 May 07
2
precedence (was 'historical NA question')
Hadley asked about the Blue book; my shelf still has the earlier brown book Becker and Chambers, 1984, S: An interactive environment for data analysis and graphics. The manual page for precedence is $ component select %x special operator - unary minus : sequence operator ^ ** exponentiation * / mult/div + -
2003 Oct 31
4
Array Dimension Names
I would like to reference array dimensions by name in an apply and a summary function. For example: apply(x, "workers", sum) Is there a better way to do this than creating a new attribute for the array and then creating new methods for apply and summary? I don't want to name the individual elements of each dimension (such as with dimnames) but rather name the dimensions. Thanks
2003 Oct 28
2
proposal for "strict" versions of subsetting operators
I'd like to propose adding "strict" versions of the subsetting operators "[", "[[", and "$" to the R language. These strict versions would be intended for use in programming rather than in interactive use. They do not perform any form of partial string matching or opportunistic simplification such as dimension dropping by default. They allow more
2006 Jun 24
1
Ops.Date: promote characters to Dates?
Ops.Date <- function (e1, e2) { if (nargs() == 1) stop("unary ", .Generic, " not defined for Date objects") boolean <- switch(.Generic, "<" = , ">" = , "==" = , "!=" = , "<=" = , ">=" = TRUE, FALSE) if (!boolean) stop(.Generic, " not defined for Date