Skip to Content
R Programming By Example
book

R Programming By Example

by Omar Trejo Navarro
December 2017
Beginner to intermediate
470 pages
12h 29m
English
Packt Publishing
Content preview from R Programming By Example

The basic variables

Let's start from the most simple scenario we can imagine and try to find any potential problems we may encounter. For each sale, we would like to have the following variables, the sales DATE, the COST for producing that type of food, the QUANTITY bought, the PRICE for the type food, whether or not we applied a DISCOUNT, the macronutrient percentages for CARBS (carbohydrates), PROTEIN, and FAT, the PROTEIN_SOURCE of the food (either FISH, CHICKEN, BEEF, or VEGETARIAN, if the person does not eat meat), the STORE where it was sold, the DELIVERY method (either send TO LOCATION or deliver IN STORE), the STATUS of the sale, which can be PENDING, DELIVERED, RETURNED, or CANCELLED (a sale can't have two statuses at the same time), ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Efficient R Programming

Efficient R Programming

Colin Gillespie, Robin Lovelace
R Programming

R Programming

Jared P. Lander

Publisher Resources

ISBN: 9781788292542Supplemental Content