Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Dummy Variables
I have a column of 4 different Letters(H,B,A,S) and i want to create three
different dummy columns of 1's and 0's to do a regression. How do i create an if statement to say if column A is H then 1 if not then 0? I've tried: =if(A2=H,1,0) and it said there was Name error Help Please |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Dummy Variables
=IF(A2="H",1,0)
"rz-illini85" wrote: I have a column of 4 different Letters(H,B,A,S) and i want to create three different dummy columns of 1's and 0's to do a regression. How do i create an if statement to say if column A is H then 1 if not then 0? I've tried: =if(A2=H,1,0) and it said there was Name error Help Please |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Dummy Variables
=--A2="H"
etc. -- --- HTH Bob (change the xxxx to gmail if mailing direct) "rz-illini85" wrote in message ... I have a column of 4 different Letters(H,B,A,S) and i want to create three different dummy columns of 1's and 0's to do a regression. How do i create an if statement to say if column A is H then 1 if not then 0? I've tried: =if(A2=H,1,0) and it said there was Name error Help Please |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
Dummy Variables
Bob
Wouldn't that need to be: =--(A2="H") Richard Bob Phillips wrote: =--A2="H" etc. -- --- HTH Bob (change the xxxx to gmail if mailing direct) "rz-illini85" wrote in message ... I have a column of 4 different Letters(H,B,A,S) and i want to create three different dummy columns of 1's and 0's to do a regression. How do i create an if statement to say if column A is H then 1 if not then 0? I've tried: =if(A2=H,1,0) and it said there was Name error Help Please |
#5
Posted to microsoft.public.excel.misc
|
|||
|
|||
Dummy Variables
Of course it would, I kep making that error <g
Bob (change the xxxx to gmail if mailing direct) "RichardSchollar" wrote in message oups.com... Bob Wouldn't that need to be: =--(A2="H") Richard Bob Phillips wrote: =--A2="H" etc. -- --- HTH Bob (change the xxxx to gmail if mailing direct) "rz-illini85" wrote in message ... I have a column of 4 different Letters(H,B,A,S) and i want to create three different dummy columns of 1's and 0's to do a regression. How do i create an if statement to say if column A is H then 1 if not then 0? I've tried: =if(A2=H,1,0) and it said there was Name error Help Please |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Creating dummy variables in Excel | Excel Worksheet Functions | |||
Creating dummy variables in Excel | Excel Worksheet Functions | |||
RE-submitting of: constructing (complex) variables with worksheet functions | Excel Worksheet Functions | |||
VBA reseting variables | Excel Discussion (Misc queries) | |||
How to hide a dummy series in a chart legend? | New Users to Excel |