Message Boards Message Boards

Create a scatter plot with two economic variables, x & y, for each country?

GROUPS:

I have two vectors of equal length downloaded from the internet. They relate to two economic variables, x and y, in 100 countries. How do I get a graph of y as a function of x so I can visualize the relation?

POSTED BY: Emilio Venezian
Answer
2 months ago

You can try

twoVectors = {{1, 2, 3, 4, 5, 6}, {3, 1, 5, 3, 7, -1}};
ListPlot[Transpose[twoVectors]]

There is a tutorial on "Plotting lists of data": http://reference.wolfram.com/language/tutorial/PlottingListsOfData.html

POSTED BY: Gianluca Gorni
Answer
2 months ago

Group Abstract Group Abstract