Immport Webanno TSV file with headers in the table

59 views
Skip to first unread message

Richenda Wright

unread,
May 10, 2022, 9:01:13 AM5/10/22
to webanno-user
Dear all,

I have finished curating documents on WebAnno and would like to import them into R for data processing and quantitative analysis.

Importing the TSV file works well and columns are named V1, V2 etc. The problem is that different files have a different number of columns because a different number of aspects were tagged in different documents. (example attached)

My question is if anyone knows a script to assign the commented column headers at the top of the screen to the columns, so that they can be merged together by name instead of by column number later?

Any help in this regard is highly appreciated!

Best wishes,
Richenda
sample.jpg

Richard Eckart de Castilho

unread,
May 10, 2022, 10:19:11 AM5/10/22
to Richenda Wright, webanno-user
Hi Richenda,

while I don't have a solution for you for R, you might try posting the question
also to mailing list of the WebAnno "successor" INCEpTION:

https://groups.google.com/d/forum/inception-users

If you know Python, you might it viable to export your annotations as UIMA CAS XMI
and then use dkpro cassis [1] to load the files, extract the data you need
into e.g. a Pandas data frame and then write it out again into a CSV that
could then go into R.

-- Richard

[1] https://github.com/dkpro/dkpro-cassis
Reply all
Reply to author
Forward
0 new messages