Description Usage Arguments Value Author(s) Examples
View source: R/funcs_multilateral.R
This function computes growth rates of variables for panel data sets.
1 | growth(dataset, var.agg)
|
dataset |
A data frame containing numerical data, id and time variables. The panel should be arranged in long format. |
var.agg |
The name of id variables contained in the dataset. The temporal dimension should be the first element while the spatial should be the second one. |
It returns the data frame of growth rates indexed by time and id.
Edoardo Baldoni
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | library(parallel)
library(igraph)
library(ape)
data('multil_data')
indx = multilateral(dat.q,dat.p,var.agg=c('year','region'),
transitivity = 'mst', bench = 1, period =2010,
idx = 'fisher', PAR= FALSE, Cores = detectCores(),plotting= FALSE)
indx = as.data.frame(do.call('cbind',list(indx)))
names(indx) = 'indx'
## try
indx$year = substr(rownames(indx),start=nchar(rownames(indx))-3,stop=nchar(rownames(indx)))
indx$region = substr(rownames(indx),start=nchar(rownames(indx))-6,stop=nchar(rownames(indx))-5)
growth(indx, var.agg=c('year','region'))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.