SOLVED
Need to create a new column based on data in another column
Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
InfoManager
7 - Meteor
‎11-10-2017
05:26 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Having a bit of a difficult time with this one. I'm new to Alteryx and still learning the ropes.
Based on the data contained in one column of my workbook, I need to create another column with different data. For example:
Country | Year |
USA | 2015 |
USA | 2016 |
France | 2016 |
Japan | 2015 |
USA | 2014 |
What I would like to have is something that looks like this:
Country | US or Non-US | Year |
USA | USA | 2015 |
USA | USA | 2016 |
France | Non-US | 2016 |
Japan | Non-US | 2015 |
USA | USA | 2014 |
I tried to look for a formula that would create values in a new column (US or Non-US) based on the values in the Country column, but I can't seem to figure it out. Any help would be greatly appreciated!
Megan
Solved! Go to Solution.
Labels:
- Labels:
- Expression
- Preparation
- Tips and Tricks
2 REPLIES 2
JoshKushner
12 - Quasar
‎11-10-2017
05:28 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Try this out!
Add a new field in the formula bar and name the field what you like with the formula:
IIF([Country] = "USA", "USA", "Non-US")
Add a new field in the formula bar and name the field what you like with the formula:
IIF([Country] = "USA", "USA", "Non-US")
‎11-10-2017
05:40 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
So easy! Thank you!