## Scatter plots

Let's start with scatter plots. Assume that your data has variable A and variable B with a lot of values. You need to find a correlation between variable A and variable B. Before you find the correlation, you need to plot the scatter graph of these two variables.

Select **twoway** graphs from the Stata tool list and follow the following steps:

Click on the

**Create**button. Here is what the box will look like:Select

**Basic plots**and select the type of the plot as**Scatter**plot.Select

**X**and**Y**variable, as shown in the next screenshot:Click on the

**Accept**button after performing the required changes, as shown in the preceding screenshot.Your output window will open with scatter plot, as shown in the next screenshot:

What if you need to add more variables and create complex scatter plots? You can add as many variables as you want and observe the clusters that are naturally available in the scatter plot. Here is a procedure to perform this:

Click on the

**graphing**tool again.In the list of variables...