0
ここで別の質問からいくつかのデータです:私は、最初の列は、実際にインデックスされ、最初の2行は、マルチレベルの列場所として扱われるように、このデータで読みたいpd.read_clipboardを使用して複数レベルの列を指定しますか?
main Meas1 Meas2 Meas3 Meas4 Meas5
sublvl Value Value Value Value Value
count 7.000000 1.0 1.0 582.00 97.000000
mean 30 37.0 26.0 33.03 16.635350
は、 MeasX
が第1レベル、Value
が第2レベルです。
pd.read_clipboard
を使ってどうすればいいですか?
マイpd.read_clipboard
シリーズ:
How do you handle column names having spaces in them when using pd.read_clipboard?
How to handle custom named index when copying a dataframe using pd.read_clipboard?
この回答について私が本当に驚いたのは、私がそれにどれくらい近づいたかということです: 'pd.read_clipboard(index = [0]、header = [1,2])' –
、2] 'MultiIndexを返しません... – unutbu
おそらく' index_col'の代わりに 'index'のような他のダムの間違いのせいで、sep ...などを指定していないので、私は学ぶべきことがたくさんあります。 –