r.squared {plm}R Documentation

R squared for panel data

Description

This function computes the R squared for plm objects. It allows to define on which transformation of the data the R squared has to be computed and which formula should be used

Usage

r.squared(object, model = NULL, type = c('cor', 'rss', 'ess'), dfcor = FALSE)

Arguments

object

an object of class "plm",

model

on which transformation of the data the R-squared has to be computed ? If null the transformation used to estimate the model is also used for the computation of the R squared.

type

should the R-squaredcomputed using the residual sum of squares ("rss"), the explained sum of squares ("ess") or the coefficient of correlation between the fitted values and the response (cor).

dfcor

if TRUE, the adjusted R squared is computed.

Value

a numerical value


[Package plm version 1.2-10 Index]