Extract and analyze the input data provided from Open Spending API, using the cl.analysis
function.
open_spending.cl(json_data, dimensions=NULL, amounts=NULL, measured.dimensions=NULL,
cl.aggregate="sum", cl.method=NULL, cl.num=NULL, cl.dist="euclidean")
The json string, URL or file from Open Spending API
The dimensions/feature of the input data
The measures of the input data
The dimensions to which correspond amount/numeric variables
Aggregate function of the input data
The clustering algorithm
The number of clusters
The distance metric
A json string with the resulted parameters of the cl.analysis
function.
This function is used to read data in json format from Open Spending API, in order to implement
cluster analysis through cl.analysis
function.