CategoryFootnotes Method (R)
.CategoryFootnotes(object,dimPlace,dimName,category,footnotes). Used to add a footnote to a specified category.
- The argument object is a reference to the associated
BasePivotTable
object. - The argument dimPlace specifies the dimension type associated
with the category, using one member from a set of built-in object
properties:
Dimension.Place.row
for a row dimension,Dimension.Place.column
for a column dimension, andDimension.Place.layer
for a layer dimension. - The argument dimName is the string that specifies the dimension
name associated with the category. This is the name specified when
the dimension was created by the
Append
orInsert
method. - The argument category specifies the category and must be
a CellText object
(one of
CellText.Number
,CellText.String
,CellText.VarName
, orCellText.VarValue
). - The argument footnotes is a string specifying the footnote.
Example
table = spss.BasePivotTable("Table Title",
"OMS table subtype")
rowdim=BasePivotTable.Append(table,Dimension.Place.row,"row dimension")
coldim=BasePivotTable.Append(table,Dimension.Place.column,"column dimension")
row_cat1 = spss.CellText.String("first row")
row_cat2 = spss.CellText.String("second row")
col_cat1 = spss.CellText.String("first column")
col_cat2 = spss.CellText.String("second column")
BasePivotTable.SetCategories(table,rowdim,list(row_cat1,row_cat2))
BasePivotTable.SetCategories(table,coldim,list(col_cat1,col_cat2))
BasePivotTable.CategoryFootnotes(table,Dimension.Place.row,"row dimension",
row_cat1,"A category footnote")