Displaying 5 results from an estimated 5 matches for "var_i".
Did you mean:
var_t
2017 Oct 09
1
Using response variable in interaction as explanatory variable in glm crashes R
...ccurances of the LHS of the formula from the RHS when building
the model matrix and it does work fine in the integer case.
Part of the culprit code may be this (from line 717),
with the isLogical(.) which in our case, shifts the pointer by
1 in the call to firstfactor() :
int adj = isLogical(var_i)?1:0;
// avoid overflow of jstart * nn PR#15578
firstfactor(&rx[jstart * nn], n, jnext - jstart,
REAL(contrast), nrows(contrast),
ncols(contrast), INTEGER(var_i)+adj);
then in firstfactor(), we see the segfault (when running R with
'-d gdb') :
> model.matr...
2012 Jun 28
4
Printing a variable in a loop
Dear R Users:
I'm a STATA user converting to R, and I'd like to be to do the following.
#Assign var_1 and var_2 a value
10->var1
20->var2
#Now I'd like to print the values of var_1 and var_2 by looping through
var_1 and var_2 in such a manner:
while(y<3){
print(var_y)
y+1->y
}
In STATA, the "y" appended to " var_" is called the local variable and
2017 Oct 06
2
Using response variable in interaction as explanatory variable in glm crashes R
The following code crashes R (I know I shouldn't try to estimate such a
model; this was a bug in some code of mine). I also tried with R-devel;
same result.
tab <- structure(list(dob_day = c(FALSE, FALSE, FALSE, FALSE, TRUE,
TRUE, TRUE, TRUE), dob_mon = c(FALSE, FALSE, TRUE, TRUE, FALSE,
FALSE, TRUE, TRUE), dob_year = c(FALSE, TRUE, FALSE, TRUE, FALSE,
TRUE, FALSE, TRUE), n =
2001 Apr 03
2
Still need help w/ making a table
Greetings again. I'm still trying to coerce a pile of data into a
frequency table format. I've managed to do so using perl, so I now have a
tab-delimited file that contains the contingency table I'm trying to use:
Group var1 var2 ... varn
B 42 11 3
C 44 1 12
...
X 12 0 19
I can read the table in using read.table(), but I end
2005 Mar 29
6
Aggregating data (with more than one function)
I have the data similar to the following in a data frame:
LastName Department Salary
1 Johnson IT 56000
2 James HR 54223
3 Howe Finance 80000
4 Jones Finance 82000
5 Norwood IT 67000
6 Benson Sales 76000
7 Smith Sales 65778
8 Baker HR 56778
9 Dempsey HR 78999
10 Nolan