Displaying 20 results from an estimated 5000 matches similar to: "new standardised variable based on group membership"
2007 Sep 18
2
How to Standardise the x/y coordinates to the unit square?
Dear Rusers, I want to standardise the values of x/y coordinates to the unit square, i.e. make the x-values all lie within [0,1] and all the y-values lie within [0,1] in the bottom example. I had thought to use scale() function to do it, but it seems that it's used to standardise a variable and the scaled value was not within [0,1]. OR, i can divide x/y-values by their maximum value to get
2011 Aug 22
3
Multiple regression in R - unstandardised coefficients are a different sign to standardised coefficients, is this correct?
Hello,
I have a statistical problem that I am using R for, but I am not making
sense of the results. I am trying to use multiple regression to explore
which variables (weather conditions) have the greater effect on a local
atmospheric variable. The data is taken from a database that has 20391 data
points (Z1).
A simplified version of the data I'm looking at is given below, but I have
a
2011 Jun 30
2
sdev value returned by princomp function (used for PCA)
Dear all,
I have a question about the 'sdev' value returned by the princomp function (which does principal components analysis).
On the help page for princomp it says 'sdev' is 'the standard deviations of the principal components'.
However, when I calculate the principal components for the USArrests data set, I don't find this to be the case:
Here is how I
2006 Apr 05
1
hist function: freq=FALSE for standardised histograms
Dear All,
I am a undergraduate using R for the first time. It seems like an excellent
program and one that I look forward to using a lot over the next few years,
but I have hit a very basic problem that I can't solve.
I want to produce a standardised histogram, i.e. one where the area under
the graph is equal to 1. I look at the manual for the histogram function and
find this:
freq:
2005 Jan 18
0
standardised residuals using standard deviation
Dear R-users,
I need to standardize residuals using standard deviation. Is the
'stdres' the proper function? Beside other methods (for standardization
and normalization), are there some approaches how to standardize using
standard deviation?
Here is the sample of my residuals:
Zres040 Zres0820 Sres040 Sres0820 PCres040
-2.101740 -2.0682900 1.6328500 0.5046730
2002 Jul 01
2
file renaming utility
Does anyone out there already have a utility to rename ogg files based
on the tags? I want to re-standardise on "[track number] - [artist] -
[track name].ogg" but my files are currently not that. It should be
easy enough, as everything is tagged, but I'm sure someone else has
written this already. Or are there Perl libraries to read tags?
Otherwise I'll have to do it then donate
2014 Sep 29
3
[LLVMdev] [cfe-dev] Proposal to add Bitcode version field to bitcode file wrapper
On 29 September 2014 15:16, Robinson, Paul
<Paul_Robinson at playstation.sony.com> wrote:
> That promise is what I understood from a discussion within the past month,
> e.g. http://lists.cs.uiuc.edu/pipermail/llvmdev/2014-September/076815.html
> If I misunderstood, clarification on the clarification would be helpful. ;-)
I see, I missed that one. My concerns seem to be similar to
2009 Nov 29
3
How to z-standardize for subgroups?
Hi folks,
I have a dataframe df.vars with the follwing structure:
var1 var2 var3 group
Group is a factor.
Now I want to standardize the vars 1-3 (actually - there are many
more) by class, so I define
z.mean.sd <- function(data){
return.values <- (data - mean(data)) / (sd(data))
return(return.values)
}
now I can call for each var
z.var1 <- by(df.vars$var1, group,
2012 Feb 23
1
(no subject)
Dear Helpers,
I wrote a simple function to standardise variables if they contain more than one value. If the elements of the variable are all identical, then I want the function to return zero.
When I submit variables whose elements are all identical to the function, it returns not zero, but NaNs.
zt=function(x){if (length(table(x)>1)) y=(x-mean(x))/sd(x) else if (length(table(x)==1)) y=0;
2010 Dec 21
0
[LLVMdev] Function-level metadata for OpenCL (was Re: OpenCL support)
> From: Peter Collingbourne [mailto:peter at pcc.me.uk]
> Sent: 20 December 2010 20:11
> As with __local variables, it may be that "kernelness" cannot be
> represented in a standard form in LLVM. For example on a CPU a
> kernel function may have an additional parameter which is a pointer to
> __local memory space, which would not be necessary on GPUs. Then in
>
2012 Nov 01
1
fitting weibull curve to data using nls
Hi
I'd like to fit an asymmetrical curve function to some physiological data. I've been told a weibull curve is a good place to start, but I'm having trouble specifying and fitting the function with nls and was wondering if someone could help.
After some reading, I think the function specification I want is
y=c*(x/a)^(b-1)*e^(-(x/a)^b)
(from
2012 Feb 23
1
FW: NaN from function
Dear Helpers,
I wrote a simple function to standardise variables if they contain more than one value. If the elements of the variable are all identical, then I want the function to return zero.
When I submit variables whose elements are all identical to the function, it returns not zero, but NaNs.
zt=function(x){if (length(table(x)>1)) y=(x-mean(x))/sd(x) else if (length(table(x)==1)) y=0;
2010 Dec 20
6
[LLVMdev] Function-level metadata for OpenCL (was Re: OpenCL support)
On Fri, Dec 17, 2010 at 04:21:18PM -0500, David Neto wrote:
> However we record the fact that a function is a kernel, the mechanism
> should handle the case of a kernel calling another kernel.
> Recall that a kernel called by another kernel behaves more like a
> regular function. For example it doesn't have workspace iteration
> automatically applied to it; rather it just
1999 Sep 22
1
model.matrix() (PR#285)
I was alarmed to discover that model.matrix.default() can permute columns
with respect to the formula. This seems to happen with user-defined
components of the formula. Thus
X <- matrix(1:4, 1, 4, dimnames = list(NULL, LETTERS[1:4]))
Q <- function(x) x^2 # because model.matrix() does not like, eg, A:A
model.matrix(~ -1 + A + A:B + Q(C), data.frame(X))
has columns ordered A, Q(C), and
2010 Dec 25
4
2 Ethernet cabling question
Two questions that was not always clear for me [sorry for posting to this list :\]:
##############################################################################################
Q1) when cabling, is the color order important? like:
straight cabling:
A side: white-orange, orange, white-green, blue, white-blue, green, white-brown, brown
B side: white-orange, orange, white-green, blue,
2003 Nov 16
3
an object of class lm returned by lm?
Can someone tell me what an object of class lm returned by lm means? I
assumed it mean the regression model - but I'm not sure how to enter
this in. I have tried
y~a+b
but this is not working. I have also tried saving the regression
results and entering these, but again this is incorrect.
This language is from the following:
lm.LMtests(model, listw, zero.policy=FALSE,
2007 Jun 30
3
transactions with two models
Hi,
In Agile Web Development with Rails section on Transactions (p 381)
there are two main examples.
1) making changes in two records in the same database table
2) making changes in two records each in a different *database*
I want to do what is in between: changes in two records each in a
different table of the same database. Suppose they are apples and
oranges tables.
How do I write this?
2012 Dec 19
2
read.csv reads more rows than indicated by wc -l
When I have a csv file that is more than 6 lines long, not including
the header, and one of the fields is blank for the last few lines, and
there is an extra comma on of the lines with the blank field,
read.csv() makes creates an extra line.
I attached an example file; I'll also paste the contents here:
A,apple
A,orange
A,orange
A,orange
A,orange
A,,,
A,,
-----
wc -l reports that this file
2020 Mar 23
4
[RFC] Coding standard for error/warning messages
Hi all,
This came up in a recent review. There is currently no documented style for
how to write error messages. For example, should they start with a capital
letter or end in a full stop? Consequently, there's quite a bit of
inconsistency in our diagnostics throughout the code base.
clang typically emits error messages with no leading capital letter and no
trailing full stop. For example:
2010 Jun 28
2
Note on PCA (not directly with R)
Dear all, I am looking for some interactive study materials on Principal
component analysis. Basically I would like to know what we are actually
doing with PCA? What is happening within the dataset at the time of doing
PCA.
Probably a 3-dimensional interactive explanation would be best for me.
I have gone through some online materials specially Wikipedia etc, however
what I need a "movable