spsspkg.StartProcedure Function (R)
spsspkg.StartProcedure(pName,omsId=pName). Signals the beginning of pivot table or
text block output. The StartProcedure-EndProcedure block is used to group output under a common heading, as is typical
for output associated with a given procedure.
- The argument pName is a string and is the name that appears in the outline pane of
the Viewer associated with the output. If the optional argument omsId is omitted, then pName is also the command name associated with this output
when routing it with OMS (Output Management System), as used in the
COMMANDSkeyword of theOMScommand. - The optional argument omsId is a string and is the command name associated with this output
when routing it with OMS (Output Management System), as used in the
COMMANDSkeyword of theOMScommand. If omsId is omitted, then the value of the pName argument is used as the OMS identifier. omsId is only necessary when creating procedures with localized output so that the procedure name can be localized but not the OMS identifier. See the topic Localizing Output from R for more information. - You can include multiple pivot tables and text blocks
in a given
StartProcedure-EndProcedureblock. - In order that names associated with output not conflict with names of existing IBM® SPSS® Statistics commands (when working with OMS), consider using names of the form yourorganization.com.procedurename.
- Call the
EndProcedurefunction to signal the end of pivot table or text block output. - Within a
StartProcedure-EndProcedureblock you cannot call thespssdictionary.SetDictionaryToSPSS,spssdata.SetDataToSPSS, orspsspkg.Submitfunctions.
Example
BEGIN PROGRAM R.
spsspkg.StartProcedure("MyProcedure")
demo <- data.frame(A=c("1A","2A"),B=c("1B","2B"),row.names=c(1,2))
spsspivottable.Display(demo,
title="Sample Pivot Table",
rowdim="Row",
hiderowdimtitle=FALSE,
coldim="Column",
hidecoldimtitle=FALSE)
spsspkg.EndProcedure()
END PROGRAM.