给定时间戳数据,我想计算过去4-6天的某些变量的中位数。过去1-3天的中位数可以由pd.pandas.DataFrame.rolling计算,但我找不到如何使用滚动来计算过去4-6天的中位数。6 days2 2011-014-6 days
6 2011-01-02 12:00:00 1.744812 NaN #
我有一个CSV文件,它包含图书章节,或者是单个章节,或者是由逗号分隔的章节范围,例如1,2,4-6,12。给定这个输入'1,2,4-6,12',我想要一个列表['1','2','4','5','6','12']作为输出chps=[str(x) for x in chp_range(entry函数chp_range('4-6')返回一个range(4,6)对象。
我
给定一个列表或分隔字符串,输出一个列表或分隔字符串,每个单词的第一个字符在一个字后输出。例如,以“下午好,世界!”(空格分隔):"Good afternoon, World!"
"[G]ood [a]fternoon, [W]orld!"
3. Move the characters over. The character at the end gets moved to the b