Cookies help us display personalized product recommendations and ensure you have great shopping experience.

By using this site, you agree to the Privacy Policy and Terms of Use.
Accept
SmartData CollectiveSmartData Collective
  • Analytics
    AnalyticsShow More
    sales and data analytics
    How Data Analytics Improves Lead Management and Sales Results
    9 Min Read
    data analytics and truck accident claims
    How Data Analytics Reduces Truck Accidents and Speeds Up Claims
    7 Min Read
    predictive analytics for interior designers
    Interior Designers Boost Profits with Predictive Analytics
    8 Min Read
    image fx (67)
    Improving LinkedIn Ad Strategies with Data Analytics
    9 Min Read
    big data and remote work
    Data Helps Speech-Language Pathologists Deliver Better Results
    6 Min Read
  • Big Data
  • BI
  • Exclusive
  • IT
  • Marketing
  • Software
Search
© 2008-25 SmartData Collective. All Rights Reserved.
Reading: Would You Prefer Prettier Pivot Tables?
Share
Notification
Font ResizerAa
SmartData CollectiveSmartData Collective
Font ResizerAa
Search
  • About
  • Help
  • Privacy
Follow US
© 2008-23 SmartData Collective. All Rights Reserved.
SmartData Collective > Uncategorized > Would You Prefer Prettier Pivot Tables?
Uncategorized

Would You Prefer Prettier Pivot Tables?

Editor SDC
Editor SDC
4 Min Read
SHARE

I have heard from users that they often need to enhance the formatting of SPSS Statistics pivot tables beyond what can be done with tableLooks. Until recently there have been three ways to do this: tedious manual formatting, exporting to Excel and (tediously) formatting there, and writing a fairly complicated Basic or – starting […]

I have heard from users that they often need to enhance the formatting of SPSS Statistics pivot tables beyond what can be done with tableLooks. Until recently there have been three ways to do this: tedious manual formatting, exporting to Excel and (tediously) formatting there, and writing a fairly complicated Basic or – starting with version 16 – Python script. Now there’s a fourth way that is very powerful and much easier to use. And it doesn’t require any programming knowledge.

SPSSINC MODIFY TABLES is an extension command with a custom dialog box interface that is available from Developer Central for Version 17. I’ll explain some of its features with an example.

More Read

Bing vs. Google
FTC Privacy Report Wants “Do Not Track” for Consumers
saP or saS or sasR or saaS
The ROI of Measuring Social Media ROI
Why LinkedIn Frustrates Me

Here is a crosstab table (from the Crosstabs case study) showing customer satisfaction with different stores controlling by whether they had contact with a store employee or not.

The original crosstab with a tableLook applied

The original crosstab with a tableLook applied

TableLooks are good for static formatting and can be applied automatically, but they apply to whole areas of tables and are static.

The table cells contain counts and residuals. There is a story in this table that takes time to find. To bring out that story, we could highlight the large residuals. You can do that manually cell by cell, but that is tedious and error prone. The SPSSINC MODIFY TABLES command can automate this.

SPSSINC MODIFY TABLES can select cells based on the row or column label text, the indexes, and/or the cell values, and it can apply most of the formatting devices that you could use interactively, even hiding unwanted rows or columns. Here is an example that looks for the cell residuals and creates a red background if the residual is large.

SPSSINC MODIFY TABLES SUBTYPE='Crosstabulation'
DIMENSION=ROWS SELECT='Std. Residual'
/STYLES TEXTSTYLE=BOLD BACKGROUNDCOLOR=255 0 0
APPLYTO='abs(x) >2'.

I would run this right after the CROSSTAB syntax. It selects tables of OMS type “Crosstabulation” in that output; looks in the rows for the label “Std. Residual”, and makes the text bold and the background red (colors are RedGreenBlue numbers between 0 and 255). The APPLYTO keyword specifies that this only happen if the cell value is greater than 2 in absolute value.

Here’s the result.

The large residuals are bold and red

The large residuals are bold and red

The report has been turned into a message: there are issues with Store 2.

We can go further with this command. I’ll discuss that in another post, but before I go, I want to mention that this extension command has a custom dialog box available on the Utilities menu after you install it.

You can get the command and dialog interface from the Downloads section of SPSS Developer Central (linked at the top of this site).

I would be interested in hearing about particular formatting requirements you have for tables. I’m betting that most of them can be handled by this command.

Share This Article
Facebook Pinterest LinkedIn
Share

Follow us on Facebook

Latest News

sales and data analytics
How Data Analytics Improves Lead Management and Sales Results
Analytics Big Data Exclusive
ai in marketing
How AI and Smart Platforms Improve Email Marketing
Artificial Intelligence Exclusive Marketing
AI Document Verification for Legal Firms: Importance & Top Tools
AI Document Verification for Legal Firms: Importance & Top Tools
Artificial Intelligence Exclusive
AI supply chain
AI Tools Are Strengthening Global Supply Chains
Artificial Intelligence Exclusive

Stay Connected

1.2kFollowersLike
33.7kFollowersFollow
222FollowersPin

You Might also Like

Mobile Business Intelligence: Who is Hot in 2014?

6 Min Read

Effective Meetings

7 Min Read

Guest Post by Brent Arslaner: The Next Generation of Lead Generation

8 Min Read

Overcoming the Barriers to IM Success: Learn from the Past.

4 Min Read

SmartData Collective is one of the largest & trusted community covering technical content about Big Data, BI, Cloud, Analytics, Artificial Intelligence, IoT & more.

AI and chatbots
Chatbots and SEO: How Can Chatbots Improve Your SEO Ranking?
Artificial Intelligence Chatbots Exclusive
ai chatbot
The Art of Conversation: Enhancing Chatbots with Advanced AI Prompts
Chatbots

Quick Link

  • About
  • Contact
  • Privacy
Follow US
© 2008-25 SmartData Collective. All Rights Reserved.
Go to mobile version
Welcome Back!

Sign in to your account

Username or Email Address
Password

Lost your password?