Skip to content

Commit ed58506

Browse files
committed
Added Author Profile Menu in Biblioshiny
1 parent 9f9ed5b commit ed58506

File tree

3 files changed

+119
-13
lines changed

3 files changed

+119
-13
lines changed

inst/biblioshiny/helpContent.R

Lines changed: 56 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,5 +144,60 @@ helpContent <- function(){
144144
</body>
145145
"
146146

147-
return(list(biblioAI=biblioAI, info=info, publications=publications, filters=filters))
147+
authorProfile <- "
148+
<h3><strong>👤 Author Profile Overview</strong></h3>
149+
150+
<p>The Author Profile page provides a <strong>dual-perspective bibliometric overview</strong> of each author included in the collection:</p>
151+
<br>
152+
<h4><strong>🔹 Global Profile</strong></h4>
153+
<p>The <strong>Global Profile</strong> presents the author's complete scientific output, based on metadata retrieved from <a href='https://openalex.org' target='_blank'>OpenAlex</a> via the <code>openalexR</code> R package. This profile includes <em>all publications authored by the researcher</em>, regardless of whether they are part of the current collection.</p>
154+
155+
<p><strong>Main features of the Global Profile include:</strong></p>
156+
<ul>
157+
<li>Total Publications and Citations</li>
158+
<li>H-Index and i10-Index</li>
159+
<li>2-Year Mean Citation Rate</li>
160+
<li>Publication Trends over the last 10 years</li>
161+
<li>Main Research Topics extracted from OpenAlex concepts</li>
162+
</ul>
163+
164+
<p><strong>Data Source:</strong> OpenAlex API (via <code>openalexR</code>)<br>
165+
<strong>Unique Identifier:</strong> OpenAlex Author ID (e.g., <code>A5014455237</code>)</p>
166+
<br>
167+
<h4><strong>🔸 Local Profile</strong></h4>
168+
<p>The <strong>Local Profile</strong> focuses exclusively on the subset of the author's publications that are included in the <em>user-defined collection</em> currently under analysis in the project.</p>
169+
170+
<p><strong>Main features of the Local Profile include:</strong></p>
171+
<ul>
172+
<li>Number of Publications, Total Citations, and Local H-Index</li>
173+
<li>Average Citations per Work</li>
174+
<li>Recent Activity: Number of publications in the last 5 years</li>
175+
<li>Publication Trends (based only on local data)</li>
176+
<li>Main Keywords derived from the local collection</li>
177+
<li>List of Publications with full metadata (title, year, journal, DOI, citations)</li>
178+
</ul>
179+
180+
<p>This local profile helps contextualize the author's role and impact <strong>within the specific research topic or dataset</strong> under investigation.</p>
181+
<br>
182+
<h4><strong>🔄 Interpretation and Use</strong></h4>
183+
<p>The <strong>Global Profile</strong> offers a broad, external view of the author’s overall scholarly influence, while the <strong>Local Profile</strong> highlights their specific relevance <em>within the current study</em>.</p>
184+
185+
<p>This dual visualization is particularly useful for:</p>
186+
<ul>
187+
<li>Identifying influential researchers in the topic area</li>
188+
<li>Comparing local vs. global impact</li>
189+
<li>Evaluating thematic alignment of authors with the collection's focus</li>
190+
</ul>
191+
<br>
192+
<h4><strong>📚 References</strong></h4>
193+
194+
<p><strong>Priem, J. et al. (2022).</strong> <i>OpenAlex: A fully-open index of scholarly works, authors, venues, institutions, and concepts.</i> Retrieved from <a href='https://openalex.org' target='_blank'>https://openalex.org</a></p>
195+
196+
<p><strong>Aria, M., Le, T., Cuccurullo, C., Belfiore, A., & Choe, J. (2024).</strong> <i>openalexR: An R-Tool for Collecting Bibliometric Data from OpenAlex.</i> <strong>R Journal</strong>, 15(4), 167–180. <a href='https://doi.org/10.32614/RJ-2023-089' target='_blank'>https://doi.org/10.32614/RJ-2023-089</a></p>
197+
198+
<p><strong>Aria, M. et al. (2023).</strong> <i>openalexR: An R package for programmatic access to OpenAlex metadata.</i> <strong>CRAN</strong>. Retrieved from <a href='https://cran.r-project.org/package=openalexR' target='_blank'>https://cran.r-project.org/package=openalexR</a></p>
199+
200+
<p><strong>Hirsch, J.E. (2005).</strong> <i>An index to quantify an individual's scientific research output.</i> <strong>Proceedings of the National Academy of Sciences</strong>, 102(46), 16569–16572. <a href='https://doi.org/10.1073/pnas.0507655102' target='_blank'>https://doi.org/10.1073/pnas.0507655102</a></p>
201+
"
202+
return(list(biblioAI=biblioAI, info=info, publications=publications, filters=filters, authorProfile=authorProfile))
148203
}

inst/biblioshiny/server.R

Lines changed: 48 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2334,8 +2334,18 @@ To ensure the functionality of Biblioshiny,
23342334
modalAuthorBio <- function(session) {
23352335
ns <- session$ns
23362336
modalDialog(
2337-
shinycssloaders::withSpinner(uiOutput(ns("authorBioCard")), caption = HTML("<br><strong>Thinking...</strong>"),
2338-
image = "ai_small2.gif", color = "#466fc4"),
2337+
title = div("Author Profile", style = "text-align: center; margin: 0;"),
2338+
tabsetPanel(
2339+
type = "tabs",
2340+
tabPanel(
2341+
title = "Global Profile",
2342+
uiOutput(ns("AuthorBioPageUI2"))
2343+
),
2344+
tabPanel(
2345+
title = "Local Profile",
2346+
uiOutput(ns("AuthorLocalProfileUI2"))
2347+
)
2348+
),
23392349
size = "l",
23402350
easyClose = FALSE,
23412351
footer = tagList(
@@ -2352,16 +2362,42 @@ To ensure the functionality of Biblioshiny,
23522362
resetModalButtons(session = getDefaultReactiveDomain())
23532363
})
23542364

2355-
authorBioFunc <- eventReactive(ignoreNULL = TRUE,
2356-
eventExpr = {input$selected_author},
2357-
valueExpr = {
2358-
authorCard(input$selected_author, values)
2359-
})
2360-
2361-
output$authorBioCard <- renderUI({
2362-
ns <- session$ns
2363-
authorBioFunc()
2364-
})
2365+
observeEvent(
2366+
ignoreNULL = TRUE,
2367+
eventExpr = {
2368+
input$selected_author
2369+
},
2370+
handlerExpr = {
2371+
req(values$M)
2372+
selected_author <- input$selected_author
2373+
authorGlobalProfile <- authorCard(selected_author, values)
2374+
output$AuthorBioPageUI2 <- renderUI({
2375+
authorGlobalProfile
2376+
})
2377+
2378+
local_author <- values$author_data %>%
2379+
filter(AUid == selected_author) %>%
2380+
pull(display_name)
2381+
2382+
local_data <- values$M[gregexpr(selected_author,values$M$AU)>-1,] %>%
2383+
mutate(TI = to_title_case(TI),
2384+
SO= to_title_case(SO))
2385+
2386+
authorLocalProfile <- create_local_author_bio_card(
2387+
local_author_data = local_data,
2388+
selected_author = local_author,
2389+
max_py = values$M$PY %>% max(na.rm = TRUE),
2390+
width = "100%",
2391+
show_trends = TRUE,
2392+
show_keywords = TRUE,
2393+
max_keywords = 20,
2394+
max_works_display = 50
2395+
)
2396+
output$AuthorLocalProfileUI2 <- renderUI({
2397+
authorLocalProfile
2398+
})
2399+
}
2400+
)
23652401

23662402
### Most Cited Authors ----
23672403
MLCAuthors <- eventReactive(input$applyMLCAuthors,{

inst/biblioshiny/ui.R

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ biblioAI <- helpContent()$biblioAI
5252
info <- helpContent()$info
5353
pubs <- helpContent()$publications
5454
filters <- helpContent()$filters
55+
authorProfile <- helpContent()$authorProfile
5556

5657
## Header ----
5758
header <- shinydashboardPlus::dashboardHeader(
@@ -1664,6 +1665,20 @@ body <- dashboardBody(
16641665
#style = "height: 550px; overflow-y: scroll; border: 1px solid #ccc; padding: 10px; background-color: #f9f9f9;",
16651666
shinycssloaders::withSpinner(uiOutput("AuthorLocalProfileUI"))
16661667
)
1668+
),
1669+
tabPanel(
1670+
"Info & References",
1671+
fluidPage(
1672+
fluidRow(
1673+
column(1),
1674+
column(
1675+
10,
1676+
br(),
1677+
HTML(authorProfile)
1678+
),
1679+
column(1)
1680+
)
1681+
)
16671682
)
16681683
)
16691684
),

0 commit comments

Comments
 (0)