How to use the Conditional function in Alteryx

This recipe helps you use the Conditional function in Alteryx

Recipe Objective:-How to use the Conditional function in Alteryx.

Step 1:-

Open Alteryx Designer software.Here New workflow1 is by default available.

Step 2:-

Now go to the Favorite tab or IN/OUT tab where we can see a tool named as "INPUT DATA".

Step 3:-

Drag the INPUT DATA tool on the below side in the New Workflow1.Now go to the Configuration pane/window and click on the drop down available to connect a file or database.

Get Access to Plant Species Identification Project using Machine Learning

Step 4:-

After this it will redirect us to the data connection window, here we have to click on files option, then click on select file option,it will then ask us to select a file from the folder, here we have selected a file named as"Sales 2017-Copy".Then select "50 Records orders" sheet from file and click on Ok.

Step 5:-

Then click on Run button or press CTRL+R, In the results workflow data will be displayed.Drag the Formula tool from the Preparation tab and connect it with the INPUT DATA tool.

Step 6:-

Then go to the configuration pane/window, click on "+" sign so a new expression window will be opened.First select the option as "+Add column" from output column drop down, name the new column as "Sales Done" or if its already added select it .In the expression window type "Round([Sales Done],2)", the data type will be "Double" then click on Run button, the round of values will be displayed in the results workflow under the sales done field/column.

Step 7:-

Now go to to the results workflow, click on the 3 dots available at the Sales Done field/column, then sort the data in descending order (higher to lower).Then go to the configuration pane/window, click on "+" sign so a new expression window will be opened.First select the option as "+Add column" from output column drop down, name the new column as "Sales Type".In the expression window type the Condition "If [Sales Done]> 500 then "High Sales" else "Low Sales" endif", the data type will be "V_WString" then click on Run button, the results workflow will be available under the sales type field/column.

What Users are saying..

profile image

Ameeruddin Mohammed

ETL (Abintio) developer at IBM
linkedin profile url

I come from a background in Marketing and Analytics and when I developed an interest in Machine Learning algorithms, I did multiple in-class courses from reputed institutions though I got good... Read More

Relevant Projects

Build Multi Class Text Classification Models with RNN and LSTM
In this Deep Learning Project, you will use the customer complaints data about consumer financial products to build multi-class text classification models using RNN and LSTM.

Detectron2 Object Detection and Segmentation Example Python
Object Detection using Detectron2 - Build a Dectectron2 model to detect the zones and inhibitions in antibiogram images.

Learn to Build Generative Models Using PyTorch Autoencoders
In this deep learning project, you will learn how to build a Generative Model using Autoencoders in PyTorch

Build Customer Propensity to Purchase Model in Python
In this machine learning project, you will learn to build a machine learning model to estimate customer propensity to purchase.

Avocado Machine Learning Project Python for Price Prediction
In this ML Project, you will use the Avocado dataset to build a machine learning model to predict the average price of avocado which is continuous in nature based on region and varieties of avocado.

Time Series Forecasting Project-Building ARIMA Model in Python
Build a time series ARIMA model in Python to forecast the use of arrival rate density to support staffing decisions at call centres.

Hands-On Approach to Causal Inference in Machine Learning
In this Machine Learning Project, you will learn to implement various causal inference techniques in Python to determine, how effective the sprinkler is in making the grass wet.

Build ARCH and GARCH Models in Time Series using Python
In this Project we will build an ARCH and a GARCH model using Python

Build a CNN Model with PyTorch for Image Classification
In this deep learning project, you will learn how to build an Image Classification Model using PyTorch CNN

End-to-End Snowflake Healthcare Analytics Project on AWS-1
In this Snowflake Healthcare Analytics Project, you will leverage Snowflake on AWS to predict patient length of stay (LOS) in hospitals. The prediction of LOS can help in efficient resource allocation, lower the risk of staff/visitor infections, and improve overall hospital functioning.