Question
I have problem to run these two lines: it's gave me this error (ValueError: Grouper for 'Loan' not 1-dimensional) Please your help is appreciated #C
I have problem to run these two lines: it's gave me this error (ValueError: Grouper for 'Loan' not 1-dimensional)
Please your help is appreciated
#C : # To create two separate pivot tables, one for Loan as function of Online and one for Loan as function of CC, you can use the pivot_table() method twice, once with Online as the column variable and once with CC as the column variable.
pivot_table_online = train_data.pivot_table(values='Loan', index='Loan', columns='Online', aggfunc='count')
pivot_table_cc = train_data.pivot_table(values='Loan', index='Loan', columns='CC', aggfunc='count')
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started