Premium Project

Functions for Food Price Forecasts

Write functions to forecast time series of food prices in Rwanda.

Start Project
  • 12 tasks
  • 1,041 participants
  • 1,500 XP

Project Description

Writing functions make your analyses more readable and more repeatable. In this project, you'll perform an analysis of potato prices in Rwanda, using the readr skills you learned in Importing Data in R (Part 1) to read the data, then wrangling and visualizing the data with dplyr and ggplot2 skills from Introduction to the Tidyverse, manipulating dates with lubridate skills from Working with Times and Dates in R, and forecasting future prices with forecast with skills from Forecasting Using R. You'll also wrap your code into functions using skills from Introduction to Function Writing in R, in order to apply your analysis to other food types.

Project Tasks

  • 1Importing important price data
  • 2Once more, with feeling
  • 3Spring cleaning
  • 4Potatoes are not a balanced diet
  • 5Plotting the price of potatoes
  • 6What a lotta plots
  • 7Preparing to predict the future (part 1)
  • 8Preparing to predict the future (part 2)
  • 9Another day, another function to write
  • 10The future of potato prices
  • 11The final function
  • 12Do it all over again
Instructor Avatar
Richie Cotton

Head of Content Quality at DataCamp

Richie runs the Content Quality team at DataCamp. He has been using R since 2004, in the fields of proteomics, debt collection, and chemical health and safety. He has released almost 30 R packages on CRAN and Bioconductor – most famously the assertive suite of packages – as well as creating and contributing to many others. He also has written two books on R programming, Learning R and Testing R Code.

See More

Technology

  • R LogoR
  • Topics

    Data ManipulationData VisualizationImporting & Cleaning Data