我想做的事:
# I have col names in pandas DF such as :
data 2017/01 2017/02 2017/03 ....
ABC 12 22 08 ....
EFG 07 16 12 ....
Run Code Online (Sandbox Code Playgroud)
我想转换col名称:
data Jan-2017 Feb-2017 Mar-2017 ....
ABC 12 22 08 ....
EFG 07 16 12 ....
Run Code Online (Sandbox Code Playgroud)
我尝试过以下方法:
pd.to_datetime(pd.Series(['2017/01']), format="%Y/%m")
Run Code Online (Sandbox Code Playgroud)
其中,导致:
0 2017-01-01
dtype: datetime64[ns]
Run Code Online (Sandbox Code Playgroud)
但我不知道如何得到我想要的结果.任何的想法?
在Windows 8.1的笔记本电脑上,我安装了vmware和ubuntu 16.4.
我最近安装了Anaconda 2.7(x64).安装anaconda的目录是:
/home/anaconda2/
Run Code Online (Sandbox Code Playgroud)
当我尝试使用以下命令更新包时,我遇到了如下所述的错误:
conda update --all
Run Code Online (Sandbox Code Playgroud)
错误
Error: Missing write permissions in: /home/anaconda2
Run Code Online (Sandbox Code Playgroud)
我尝试使用sudo,并尝试在visudo下写下以下权限
madhu ALL=(ALL:ALL) ALL
Run Code Online (Sandbox Code Playgroud)
没有用......
有人可以帮帮我吗?
有人可以帮我解决如何使用R在文本中找到最常用的两个和三个单词吗?
我的文字是......
text <- c("There is a difference between the common use of the term phrase and its technical use in linguistics. In common usage, a phrase is usually a group of words with some special idiomatic meaning or other significance, such as \"all rights reserved\", \"economical with the truth\", \"kick the bucket\", and the like. It may be a euphemism, a saying or proverb, a fixed expression, a figure of speech, etc. In grammatical analysis, particularly in theories of …Run Code Online (Sandbox Code Playgroud)