2016-10-24 93 views
-1

我有一个excel格式的数据,如下所示。用户可以使用Excel中的“插入注释”选项将评论添加到评分列。我想提取添加到分数列中的评论并将其放在“评论”栏中。这可能吗?你能帮忙吗?创建一个添加到excel单元格的注释的新列

Report Component Score Comments 
R1   C1  1 
R2   C2  2 
R3   C3  3 
R4   C4  4 
R5   C5  5 

这是我写到目前为止的代码。不知道如何进一步进行。请帮忙。

require(readxl) 
read_excel("Testfile01.xlsx") 

回答

0

我还没有看到这种功能在read_excel,但在此期间,你可以或许只是将文件导入R.

ExtendOffice之前写使用注释到单元格的内容:

Function GetComments(pRng As Range) As String 
'Updateby20140509 
If Not pRng.Comment Is Nothing Then 
    GetComments = pRng.Comment.Text 
End If 
End Function 

然后,您可以使用GetComments函数,例如=GetComments(A1)

enter image description here

相关问题