Skip to content

Commit

Permalink
Update 93-appendixC.Rmd
Browse files Browse the repository at this point in the history
  • Loading branch information
ismayc authored Feb 12, 2024
1 parent 003bc4f commit c20456a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion 93-appendixC.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -370,4 +370,4 @@ dyRangeSelector(dygraph(flights_summarized))

<br>

The syntax here is a little different than what we have covered so far. The `dygraph` function is expecting for the dates to be given as the `rownames` of the object. We covert our data to a data frame (since tibbles don't allow for easy row name manipulation) and then remove the `date` variable from the `flights_summarized` data frame since it is accounted for in the `rownames`. Lastly, we run the `dygraph` function on the new data frame that only contains the median arrival delay as a column and then provide the ability to have a selector to zoom in on the interactive plot via `dyRangeSelector`. (Note that this plot will only be interactive in the HTML version of this book.)
The syntax here is a little different than what we have covered so far. The `dygraph` function is expecting for the dates to be given as the `rownames` of the object. We convert our data to a data frame (since tibbles don't allow for easy row name manipulation), and then remove the `date` variable from the `flights_summarized` data frame since it is accounted for in the `rownames`. Lastly, we run the `dygraph` function on the new data frame that only contains the median arrival delay as a column and then provide the ability to have a selector to zoom in on the interactive plot via `dyRangeSelector`. (Note that this plot will only be interactive in the HTML version of this book.)

0 comments on commit c20456a

Please sign in to comment.