How to identify variables of a dataset? i have a dataset of the annual sales of a bakery and i'm confused about how many variables it has. is it the number of products or the number of years? can someone help me out? thank you!


It has two variables: product and year. The dataset is this:

A dataset like this is usually made to store individual sales. The table you drew is called 'Contingency table' and it records the tally of records with a given combination of variables. The first cell (550) says that there are 550 records with Product='Loaf' and Year='2018', the second cell says that there are 583 records with Product='Loaf' and Year='2019', and so on.
From the contingency table you can make a table with three variables: product, year and sales.

A dataset like this is usually made to record the summary of sales at the end of each year.
