assign_topic.RdAssign topics to abstracts based on precalculated scores.
assign_topic( df, col.topic, threshold, topic.names = NULL, col.topic.name = "Topic", col.pmid = "PMID", discard = FALSE )
| df | Data frame containing precalculated topic scores and PubMed-IDs. |
|---|---|
| col.topic | Character vector. Vector with column names containing precalculated topic scores. |
| threshold | Integer vector. Vector containing thresholds for topic
columns. Positions in |
| topic.names | Character vector. Optional. Vector containing names of new
topics. Positions in |
| col.topic.name | String. Name of the new topic column. |
| col.pmid | String. Column containing PubMed-IDs. |
| discard | Boolean. If |
Data frame with topics based on precalculated topic scores.
Assign topics to abstracts based on precalculated scores.
assign_topic() compares different precalculated topic scores and
assigns the abstract to the topic with the highest score. If there is a
tie between topic scores, the abstract is assigned to all topics in question.
If an abstract matches no topic, it is assigned to the topic "Unknown".
calculate_score_topic(), plot_score_topic(),
add_col_topic()
Other score functions:
calculate_score_animals(),
calculate_score_biomarker(),
calculate_score_patients(),
calculate_score_topic(),
plot_score_animals(),
plot_score_biomarker(),
plot_score_patients(),
plot_score_topic()