0
나는 dataframe 그룹화 한 :팬더,
rwp_initial.df.loc[rwp_initial.df.sample_name=='sma_initial'].groupby(by=['sample_name','pH','salt','column'])['concentration'].plot(marker = 'o', rot=30)
을하고 다음과 같은 출력 얻을 :
sample_name pH salt column
sma_initial 5.7 50 5 Axes(0.125,0.125;0.775x0.775)
6 Axes(0.125,0.125;0.775x0.775)
100 7 Axes(0.125,0.125;0.775x0.775)
8 Axes(0.125,0.125;0.775x0.775)
200 9 Axes(0.125,0.125;0.775x0.775)
10 Axes(0.125,0.125;0.775x0.775)
400 11 Axes(0.125,0.125;0.775x0.775)
12 Axes(0.125,0.125;0.775x0.775)
i는 각각 pH와 소금 내에서 평균을 싶습니다을 집중. 기둥은 두 번 측정 한 동일한 샘플입니다. aggregate(np.mean)
을 사용하면 한 열의 모든 데이터 포인트의 평균이 계산됩니다.
:
rwp_initial.df.loc[rwp_initial.df.sample_name=='sma_initial'].groupby(by=['sample_name','pH','salt'])['concentration'].plot(marker = 'o', rot=30)
이