Another way to look for data in Maple is to issue the Search command. If you provide a string, you get the top few data sets for the given string. For example, following are some results related to peanuts, peanut butter, butter, and/or Canada. You can limit the search to top 10 results.
The first data set has exactly the information you were looking for: peanut butter information for Canada. This data set corresponds to the Quandl reference code: FAO/FAO_33CANADA247PEANUTBUTTER.
You can now interact with this data in a few ways, one of which is using commands. You can find out some metadata; for example, what the four columns represent:
| (1.1.1) |
You can also convert the data into, say, a :
Notice that the matrix for peanut butter information for Canada showed a larger number of rows than the dimension of M. This is because this data is only a data set reference: it contains metadata about how to retrieve the given data, but not necessarily the data itself. However, now that you have retrieved the data, it displays as follows:
You can also plot a dataset reference, using, for example, the dataplot command.
It is also possible to operate on the data, to create new values, and to select certain values, by using indexing. For example, to select years where the export value was more than 15 million US$ (that is, 15000 units of 1000 US$ each), you can do this:
Or, to create a new time series for the ratio between import and export quantities (in tonnes), you can do the following:
You can see that no export or import was recorded before about 1990; but since then, import has grown relatively.
All these interactions are also available through the context menu. If you right click on "data", shown below, you can select Plots. The context menu offers an easy interface to the powerful TimeSeriesPlot command: you can select to show all columns of the data in a single plot, all columns in separate plots, or select one of the columns you want to see.
Filtering of data is also available, by date or other quantities, as is selecting subsets of the columns. For example, if you are interested only in the export quantity and value, you can select Select columns from the context menu, select the columns of interest and hit OK, right click on the resulting time series, and select Assign to a name and select, say, exportdata as the name. You can then run a command such as the following, to plot all the export data.