Basic Data Analysis, Manipulation and Statistical Inference with Julia 0.5.0

by Yanal Kashou

Data loading


In [2]:
using DataFrames
using RDatasets

In [3]:
diamond = dataset("Ecdat", "Diamond")
head(diamond, 5)


Out[3]:
CaratColourClarityCertificationPrice
10.3DVS2GIA1302
20.3EVS1GIA1510
30.3GVVS1GIA1510
40.3GVS1GIA1260
50.31DVS1GIA1641

Descriptive Statistics


In [4]:
describe(diamond)


Carat
Min      0.18
1st Qu.  0.35
Median   0.62
Mean     0.630909090909091
3rd Qu.  0.85
Max      1.1
NAs      0
NA%      0.0%

Colour
Length  308
Type    Pooled String
NAs     0
NA%     0.0%
Unique  6

Clarity
Length  308
Type    Pooled String
NAs     0
NA%     0.0%
Unique  5

Certification
Length  308
Type    Pooled String
NAs     0
NA%     0.0%
Unique  3

Price
Min      638.0
1st Qu.  1625.0
Median   4215.0
Mean     5019.483766233766
3rd Qu.  7446.0
Max      16008.0
NAs      0
NA%      0.0%

Exploratory Plots using Gadfly


In [5]:
using Gadfly

In [6]:
diamond[:AdjustedPrice] = diamond[:Price] / 1000;

In [67]:
plot(diamond, x = "AdjustedPrice", y = "Carat", 
color = "Colour", Geom.point)


Out[67]:
AdjustedPrice -25 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40 45 -20 -19 -18 -17 -16 -15 -14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 -20 0 20 40 -20 -18 -16 -14 -12 -10 -8 -6 -4 -2 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 D E G F H I Colour -2.0 -1.5 -1.0 -0.5 0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 -1.50 -1.45 -1.40 -1.35 -1.30 -1.25 -1.20 -1.15 -1.10 -1.05 -1.00 -0.95 -0.90 -0.85 -0.80 -0.75 -0.70 -0.65 -0.60 -0.55 -0.50 -0.45 -0.40 -0.35 -0.30 -0.25 -0.20 -0.15 -0.10 -0.05 0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 0.95 1.00 1.05 1.10 1.15 1.20 1.25 1.30 1.35 1.40 1.45 1.50 1.55 1.60 1.65 1.70 1.75 1.80 1.85 1.90 1.95 2.00 2.05 2.10 2.15 2.20 2.25 2.30 2.35 2.40 2.45 2.50 2.55 2.60 2.65 2.70 2.75 2.80 2.85 2.90 2.95 3.00 -2 0 2 4 -1.5 -1.4 -1.3 -1.2 -1.1 -1.0 -0.9 -0.8 -0.7 -0.6 -0.5 -0.4 -0.3 -0.2 -0.1 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 Carat

In [70]:
plot(diamond, x = "AdjustedPrice", y = "Carat", Geom.point, 
layer(x = "AdjustedPrice", y = "Carat", Geom.smooth, Theme(default_color=colorant"red")))


Out[70]:
AdjustedPrice -25 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40 45 -20 -19 -18 -17 -16 -15 -14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 -20 0 20 40 -20 -18 -16 -14 -12 -10 -8 -6 -4 -2 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 -2.0 -1.5 -1.0 -0.5 0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 -1.50 -1.45 -1.40 -1.35 -1.30 -1.25 -1.20 -1.15 -1.10 -1.05 -1.00 -0.95 -0.90 -0.85 -0.80 -0.75 -0.70 -0.65 -0.60 -0.55 -0.50 -0.45 -0.40 -0.35 -0.30 -0.25 -0.20 -0.15 -0.10 -0.05 0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 0.95 1.00 1.05 1.10 1.15 1.20 1.25 1.30 1.35 1.40 1.45 1.50 1.55 1.60 1.65 1.70 1.75 1.80 1.85 1.90 1.95 2.00 2.05 2.10 2.15 2.20 2.25 2.30 2.35 2.40 2.45 2.50 2.55 2.60 2.65 2.70 2.75 2.80 2.85 2.90 2.95 3.00 -2 0 2 4 -1.5 -1.4 -1.3 -1.2 -1.1 -1.0 -0.9 -0.8 -0.7 -0.6 -0.5 -0.4 -0.3 -0.2 -0.1 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 Carat

In [60]:
plot(diamond, x = "Clarity", y = "AdjustedPrice", Geom.boxplot, Guide.title("My plot"), Theme(default_color = colorant"green", boxplot_spacing = 50px))


Out[60]:
Clarity VS2 VS1 VVS1 VVS2 IF -25 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40 45 -20 -19 -18 -17 -16 -15 -14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 -20 0 20 40 -20 -18 -16 -14 -12 -10 -8 -6 -4 -2 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 AdjustedPrice My plot

In [55]:
plot(diamond, x = "Colour", y = "AdjustedPrice", Geom.boxplot, Guide.title("My plot"), Theme(default_color = colorant"purple", boxplot_spacing = 50px))


Out[55]:
Colour D E G F H I -25 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40 45 -20 -19 -18 -17 -16 -15 -14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 -20 0 20 40 -20 -18 -16 -14 -12 -10 -8 -6 -4 -2 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 AdjustedPrice My plot

In [62]:
plot(diamond, x = "Price", Geom.density)


Out[62]:
Price -3.5×10⁴ -3.0×10⁴ -2.5×10⁴ -2.0×10⁴ -1.5×10⁴ -1.0×10⁴ -5.0×10³ 0 5.0×10³ 1.0×10⁴ 1.5×10⁴ 2.0×10⁴ 2.5×10⁴ 3.0×10⁴ 3.5×10⁴ 4.0×10⁴ 4.5×10⁴ 5.0×10⁴ -3.0×10⁴ -2.9×10⁴ -2.8×10⁴ -2.7×10⁴ -2.6×10⁴ -2.5×10⁴ -2.4×10⁴ -2.3×10⁴ -2.2×10⁴ -2.1×10⁴ -2.0×10⁴ -1.9×10⁴ -1.8×10⁴ -1.7×10⁴ -1.6×10⁴ -1.5×10⁴ -1.4×10⁴ -1.3×10⁴ -1.2×10⁴ -1.1×10⁴ -1.0×10⁴ -9.0×10³ -8.0×10³ -7.0×10³ -6.0×10³ -5.0×10³ -4.0×10³ -3.0×10³ -2.0×10³ -1.0×10³ 0 1.0×10³ 2.0×10³ 3.0×10³ 4.0×10³ 5.0×10³ 6.0×10³ 7.0×10³ 8.0×10³ 9.0×10³ 1.0×10⁴ 1.1×10⁴ 1.2×10⁴ 1.3×10⁴ 1.4×10⁴ 1.5×10⁴ 1.6×10⁴ 1.7×10⁴ 1.8×10⁴ 1.9×10⁴ 2.0×10⁴ 2.1×10⁴ 2.2×10⁴ 2.3×10⁴ 2.4×10⁴ 2.5×10⁴ 2.6×10⁴ 2.7×10⁴ 2.8×10⁴ 2.9×10⁴ 3.0×10⁴ 3.1×10⁴ 3.2×10⁴ 3.3×10⁴ 3.4×10⁴ 3.5×10⁴ 3.6×10⁴ 3.7×10⁴ 3.8×10⁴ 3.9×10⁴ 4.0×10⁴ 4.1×10⁴ 4.2×10⁴ 4.3×10⁴ 4.4×10⁴ 4.5×10⁴ -5×10⁴ 0 5×10⁴ -3.0×10⁴ -2.8×10⁴ -2.6×10⁴ -2.4×10⁴ -2.2×10⁴ -2.0×10⁴ -1.8×10⁴ -1.6×10⁴ -1.4×10⁴ -1.2×10⁴ -1.0×10⁴ -8.0×10³ -6.0×10³ -4.0×10³ -2.0×10³ 0 2.0×10³ 4.0×10³ 6.0×10³ 8.0×10³ 1.0×10⁴ 1.2×10⁴ 1.4×10⁴ 1.6×10⁴ 1.8×10⁴ 2.0×10⁴ 2.2×10⁴ 2.4×10⁴ 2.6×10⁴ 2.8×10⁴ 3.0×10⁴ 3.2×10⁴ 3.4×10⁴ 3.6×10⁴ 3.8×10⁴ 4.0×10⁴ 4.2×10⁴ 4.4×10⁴ 4.6×10⁴ -0.00020 -0.00015 -0.00010 -0.00005 0.00000 0.00005 0.00010 0.00015 0.00020 0.00025 0.00030 0.00035 -0.000155 -0.000150 -0.000145 -0.000140 -0.000135 -0.000130 -0.000125 -0.000120 -0.000115 -0.000110 -0.000105 -0.000100 -0.000095 -0.000090 -0.000085 -0.000080 -0.000075 -0.000070 -0.000065 -0.000060 -0.000055 -0.000050 -0.000045 -0.000040 -0.000035 -0.000030 -0.000025 -0.000020 -0.000015 -0.000010 -0.000005 0.000000 0.000005 0.000010 0.000015 0.000020 0.000025 0.000030 0.000035 0.000040 0.000045 0.000050 0.000055 0.000060 0.000065 0.000070 0.000075 0.000080 0.000085 0.000090 0.000095 0.000100 0.000105 0.000110 0.000115 0.000120 0.000125 0.000130 0.000135 0.000140 0.000145 0.000150 0.000155 0.000160 0.000165 0.000170 0.000175 0.000180 0.000185 0.000190 0.000195 0.000200 0.000205 0.000210 0.000215 0.000220 0.000225 0.000230 0.000235 0.000240 0.000245 0.000250 0.000255 0.000260 0.000265 0.000270 0.000275 0.000280 0.000285 0.000290 0.000295 0.000300 0.000305 -0.0002 0.0000 0.0002 0.0004 -0.00015 -0.00014 -0.00013 -0.00012 -0.00011 -0.00010 -0.00009 -0.00008 -0.00007 -0.00006 -0.00005 -0.00004 -0.00003 -0.00002 -0.00001 0.00000 0.00001 0.00002 0.00003 0.00004 0.00005 0.00006 0.00007 0.00008 0.00009 0.00010 0.00011 0.00012 0.00013 0.00014 0.00015 0.00016 0.00017 0.00018 0.00019 0.00020 0.00021 0.00022 0.00023 0.00024 0.00025 0.00026 0.00027 0.00028 0.00029 0.00030

In [11]:
hstack(plot(diamond, layer(x = "Certification", y = "Carat", Geom.point, Theme(default_color=colorant"red"))),
plot(diamond, layer(x = "Certification", y = "AdjustedPrice", Geom.point, Theme(default_color=colorant"navy"))),
plot(diamond, layer(x = "Clarity", y = "Carat", Geom.point, Theme(default_color=colorant"green"))),
plot(diamond, layer(x = "Clarity", y = "AdjustedPrice", Geom.point, Theme(default_color=colorant"yellow"))))


Out[11]:
Clarity VS2 VS1 VVS1 VVS2 IF -25 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40 45 -20 -19 -18 -17 -16 -15 -14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 -20 0 20 40 -20 -18 -16 -14 -12 -10 -8 -6 -4 -2 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 AdjustedPrice Clarity VS2 VS1 VVS1 VVS2 IF -2.0 -1.5 -1.0 -0.5 0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 -1.50 -1.45 -1.40 -1.35 -1.30 -1.25 -1.20 -1.15 -1.10 -1.05 -1.00 -0.95 -0.90 -0.85 -0.80 -0.75 -0.70 -0.65 -0.60 -0.55 -0.50 -0.45 -0.40 -0.35 -0.30 -0.25 -0.20 -0.15 -0.10 -0.05 0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 0.95 1.00 1.05 1.10 1.15 1.20 1.25 1.30 1.35 1.40 1.45 1.50 1.55 1.60 1.65 1.70 1.75 1.80 1.85 1.90 1.95 2.00 2.05 2.10 2.15 2.20 2.25 2.30 2.35 2.40 2.45 2.50 2.55 2.60 2.65 2.70 2.75 2.80 2.85 2.90 2.95 3.00 -2 0 2 4 -1.5 -1.4 -1.3 -1.2 -1.1 -1.0 -0.9 -0.8 -0.7 -0.6 -0.5 -0.4 -0.3 -0.2 -0.1 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 Carat Certification GIA IGI HRD -25 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40 45 -20 -19 -18 -17 -16 -15 -14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 -20 0 20 40 -20 -18 -16 -14 -12 -10 -8 -6 -4 -2 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 AdjustedPrice Certification GIA IGI HRD -2.0 -1.5 -1.0 -0.5 0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 -1.50 -1.45 -1.40 -1.35 -1.30 -1.25 -1.20 -1.15 -1.10 -1.05 -1.00 -0.95 -0.90 -0.85 -0.80 -0.75 -0.70 -0.65 -0.60 -0.55 -0.50 -0.45 -0.40 -0.35 -0.30 -0.25 -0.20 -0.15 -0.10 -0.05 0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 0.95 1.00 1.05 1.10 1.15 1.20 1.25 1.30 1.35 1.40 1.45 1.50 1.55 1.60 1.65 1.70 1.75 1.80 1.85 1.90 1.95 2.00 2.05 2.10 2.15 2.20 2.25 2.30 2.35 2.40 2.45 2.50 2.55 2.60 2.65 2.70 2.75 2.80 2.85 2.90 2.95 3.00 -2 0 2 4 -1.5 -1.4 -1.3 -1.2 -1.1 -1.0 -0.9 -0.8 -0.7 -0.6 -0.5 -0.4 -0.3 -0.2 -0.1 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 Carat

Piechart Plots Using Vega


In [28]:
using Vega

In [29]:
ColourDF = by(diamond, :Colour, nrow)


Out[29]:
Colourx1
1D16
2E44
3F82
4G65
5H61
6I40

In [30]:
ClarityDF = by(diamond, :Clarity, nrow)


Out[30]:
Clarityx1
1IF44
2VS181
3VS253
4VVS152
5VVS278

In [31]:
x1 = Array(ColourDF[:Colour])
y1 = Array(ColourDF[:x1])

x2 = Array(ClarityDF[:Clarity])
y2 = Array(ClarityDF[:x1])

Patchwork.load_js_runtime()

pie1 = piechart(x = x1, y = y1, holesize = 75)
pie2 = piechart(x = x2, y = y2, holesize = 75);


Piechart by "Colour" Column


In [33]:
pie1


Out[33]:

Piechart By "Clarity" Column


In [34]:
pie2


Out[34]:

Linear Models


In [35]:
using GLM, Distributions;

In [36]:
lm1 = fit(LinearModel, Price ~ Carat, diamond)


Out[36]:
DataFrames.DataFrameRegressionModel{GLM.LinearModel{GLM.LmResp{Array{Float64,1}},GLM.DensePredQR{Float64}},Array{Float64,2}}

Formula: Price ~ 1 + Carat

Coefficients:
             Estimate Std.Error  t value Pr(>|t|)
(Intercept)  -2298.36   158.531 -14.4979   <1e-35
Carat         11598.9   230.111  50.4057   <1e-99

In [37]:
confint(lm1)


Out[37]:
2×2 Array{Float64,2}:
 -2610.31  -1986.41
 11146.1   12051.7 

In [38]:
lm2 = fit(LinearModel, Price ~ Carat + Colour + Clarity + Certification, diamond)


Out[38]:
DataFrames.DataFrameRegressionModel{GLM.LinearModel{GLM.LmResp{Array{Float64,1}},GLM.DensePredQR{Float64}},Array{Float64,2}}

Formula: Price ~ 1 + Carat + Colour + Clarity + Certification

Coefficients:
                    Estimate Std.Error  t value Pr(>|t|)
(Intercept)          169.176   255.016 0.663395   0.5076
Carat                12766.4   190.024  67.1829   <1e-99
Colour: E           -1439.09   207.982 -6.91929   <1e-10
Colour: F           -1841.69   195.232 -9.43336   <1e-17
Colour: G           -2176.67   200.393  -10.862   <1e-22
Colour: H           -2747.15   202.914 -13.5385   <1e-32
Colour: I            -3313.1   212.715 -15.5753   <1e-39
Clarity: VS1        -1474.57   159.675  -9.2348   <1e-17
Clarity: VS2        -1792.01   171.185 -10.4682   <1e-21
Clarity: VVS1        -689.29   159.925 -4.31008    <1e-4
Clarity: VVS2       -1191.16   148.758 -8.00739   <1e-13
Certification: HRD   15.2267   107.247 0.141977   0.8872
Certification: IGI   141.262   128.258  1.10139   0.2716

Ordinary Least Squares Regression


In [39]:
GLM1 = glm(Carat ~ AdjustedPrice, diamond, Normal(), IdentityLink())


Out[39]:
DataFrames.DataFrameRegressionModel{GLM.GeneralizedLinearModel{GLM.GlmResp{Array{Float64,1},Distributions.Normal{Float64},GLM.IdentityLink},GLM.DensePredChol{Float64,Base.LinAlg.Cholesky{Float64,Array{Float64,2}}}},Array{Float64,2}}

Formula: Carat ~ 1 + AdjustedPrice

Coefficients:
                Estimate  Std.Error z value Pr(>|z|)
(Intercept)     0.244671 0.00925293 26.4425   <1e-99
AdjustedPrice  0.0769478 0.00152657 50.4057   <1e-99

In [40]:
stderr(GLM1)


Out[40]:
2-element Array{Float64,1}:
 0.00925293
 0.00152657

In [41]:
GLM1Fit = predict(GLM1);
size(GLM1Fit)


Out[41]:
(308,)

In [42]:
diamond[:GLM1Fit] = GLM1Fit;
head(diamond, 10)


Out[42]:
CaratColourClarityCertificationPriceAdjustedPriceGLM1Fit
10.3DVS2GIA13021.3020.3448569645145239
20.3EVS1GIA15101.510.3608621029445833
30.3GVVS1GIA15101.510.3608621029445833
40.3GVS1GIA12601.260.34162515771614654
50.31DVS1GIA16411.6410.37094226224428417
60.31EVS1GIA15551.5550.3643247530857019
70.31FVS1GIA14271.4270.3544754371287423
80.31GVVS2GIA14271.4270.3544754371287423
90.31HVS2GIA11261.1260.33131415507370443
100.31IVS1GIA11261.1260.33131415507370443

In [52]:
plot(diamond, layer(x = "Carat", y = "AdjustedPrice", Geom.point, Theme(default_color=colorant"blue")), 
layer(x = "GLM1Fit", y = "AdjustedPrice", Geom.line, Theme(default_color=colorant"red")))


Out[52]:
Carat -2.0 -1.5 -1.0 -0.5 0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 -1.50 -1.45 -1.40 -1.35 -1.30 -1.25 -1.20 -1.15 -1.10 -1.05 -1.00 -0.95 -0.90 -0.85 -0.80 -0.75 -0.70 -0.65 -0.60 -0.55 -0.50 -0.45 -0.40 -0.35 -0.30 -0.25 -0.20 -0.15 -0.10 -0.05 0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 0.95 1.00 1.05 1.10 1.15 1.20 1.25 1.30 1.35 1.40 1.45 1.50 1.55 1.60 1.65 1.70 1.75 1.80 1.85 1.90 1.95 2.00 2.05 2.10 2.15 2.20 2.25 2.30 2.35 2.40 2.45 2.50 2.55 2.60 2.65 2.70 2.75 2.80 2.85 2.90 2.95 3.00 -2 0 2 4 -1.5 -1.4 -1.3 -1.2 -1.1 -1.0 -0.9 -0.8 -0.7 -0.6 -0.5 -0.4 -0.3 -0.2 -0.1 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 -25 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40 45 -20 -19 -18 -17 -16 -15 -14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 -20 0 20 40 -20 -18 -16 -14 -12 -10 -8 -6 -4 -2 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 AdjustedPrice