Original table
[TABLE="width: 500"]
<tbody>[TR]
[TD="align: center"]Date[/TD]
[TD]
[/TR]
[TR]
[TD="align: center"]May 1, 2014[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]May 2, 2014
[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]May 3, 2014
[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]May 4, 2014[/TD]
[TD="align: center"][/TD]
[/TR]
</tbody>[/TABLE]
I have an excel table populated with 2 columns Date and Target where Target is a binary column which will be filled with either 1 or 0. I want to write a function such that if date is before May 3, 2014, then populate the Target column with 0. Otherwise, populate the column with 1.
Output I want
[TABLE="width: 500"]
<tbody>[TR]
[TD="align: center"]Date[/TD]
[TD]
[/TR]
[TR]
[TD="align: center"]May 1, 2014[/TD]
[TD="align: center"]0[/TD]
[/TR]
[TR]
[TD="align: center"]May 2, 2014
[/TD]
[TD="align: center"]0[/TD]
[/TR]
[TR]
[TD="align: center"]May 3, 2014
[/TD]
[TD="align: center"]1[/TD]
[/TR]
[TR]
[TD="align: center"]May 4, 2014[/TD]
[TD="align: center"]1[/TD]
[/TR]
</tbody>[/TABLE]
Thank you,
J
[TABLE="width: 500"]
<tbody>[TR]
[TD="align: center"]Date[/TD]
[TD]
Target
[/TD][/TR]
[TR]
[TD="align: center"]May 1, 2014[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]May 2, 2014
[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]May 3, 2014
[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]May 4, 2014[/TD]
[TD="align: center"][/TD]
[/TR]
</tbody>[/TABLE]
I have an excel table populated with 2 columns Date and Target where Target is a binary column which will be filled with either 1 or 0. I want to write a function such that if date is before May 3, 2014, then populate the Target column with 0. Otherwise, populate the column with 1.
Output I want
[TABLE="width: 500"]
<tbody>[TR]
[TD="align: center"]Date[/TD]
[TD]
Target
[/TD][/TR]
[TR]
[TD="align: center"]May 1, 2014[/TD]
[TD="align: center"]0[/TD]
[/TR]
[TR]
[TD="align: center"]May 2, 2014
[/TD]
[TD="align: center"]0[/TD]
[/TR]
[TR]
[TD="align: center"]May 3, 2014
[/TD]
[TD="align: center"]1[/TD]
[/TR]
[TR]
[TD="align: center"]May 4, 2014[/TD]
[TD="align: center"]1[/TD]
[/TR]
</tbody>[/TABLE]
Thank you,
J