如何更改图形大小和sns.relplot的样式?
我写道:
## Load in packages
import pandas as pd
import numpy as np
import scipy.stats as stats
import matplotlib.pyplot as plt
%matplotlib inline
import seaborn as sns
sns.set(style="white") #change style
sns.set_palette('viridis')
sns.set(rc={'figure.figsize':(20,16)}) # change default figure size
import os
import statsmodels.api as sm
import warnings
warnings.filterwarnings('ignore')
## Set working directory
os.chdir('/users/alissaswartz/documents/personal/cj affiliate interview')
## Import data
df = pd.read_csv('cj_affiliate_dataset.csv',low_memory= False)
df.columns = df.columns.str.strip()
df.head()
## Pairplots: Clicks by Sales, Sales Amount in USD
sns.relplot(x="clicks", y="sales", ci="sd", hue='sale_amount_usd',palette="viridis",data=df)
plt.show()
我仍然得到默认的figsize和样式:
我需要更改什么?我不确定发生了什么。