Aan de slagGa gratis aan de slag

Price changes

Scatter plots are an effective way of illustrating the relationship between two variables. In this exercise, you will examine the relationship between the daily price changes of two ETF funds: the iShares Russell 1000 Growth (IWF) and iShares Russell 2000 (IWM). There is a possibility of a relationship between the two as they both track the same type of index.

The CSV and DataFrames packages have been imported for you and the DataFrames iwf and iwm have been loaded and are available.

Deze oefening maakt deel uit van de cursus

Introduction to Data Visualization with Julia

Cursus bekijken

Oefeninstructies

  • First, import the Plots.jl package.
  • Define the price_change columns for both funds by calculating the difference between the close and open prices.
  • Create a scatter plot of the price_change's for iwf (y-axis) versus iwm (x-axis).

Praktische interactieve oefening

Probeer deze oefening eens door deze voorbeeldcode in te vullen.

# Import Plots.jl
____ ____

# Define price change
iwf[____, "____"] = iwf.____ - iwf.____
iwm[____, "____"] = iwm.____ - iwm.____

# Scatter plot of price changes
____(
	iwm.____,
	iwf.____
)
Code bewerken en uitvoeren