Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
73 changes: 55 additions & 18 deletions R/organizers.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,40 +3,76 @@ library(dplyr)
library(knitr)
library(kableExtra)

create_organizer_table <- function(table.path = file.path("..", "data", "organizers.csv"),
create_organizer_table <- function(organizers.path = file.path("..", "data", "organizers.csv"),
roles.path = file.path("..", "data", "roles.csv"),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

Can you combine "organizers.csv" and "roles.csv" to one? It would be simpler if there was only one file to fill

img.path = file.path("..", "images", "organizers"),
ncol = 5L,
align = "l") {
# Read organizer table
organizers <- read.csv(table.path, stringsAsFactors = FALSE)
organizers[["img_path"]] <- file.path(img.path, organizers[["img_path"]])

# Normalize order: if missing/blank, treat as Inf
organizers <- organizers |>
mutate(order = ifelse(is.na(order) | order == "", Inf, as.numeric(order)))
# Read both tables
organizers <- read.csv(organizers.path, stringsAsFactors = FALSE)
roles <- read.csv(roles.path, stringsAsFactors = FALSE)

# Add organizer group
df <- organizers |>
arrange(order, name) |>
# Merge the data
df <- merge(organizers, roles, by = "name", all = TRUE)

# Add full image path
df[["img_path"]] <- ifelse(
!is.na(df[["img_path"]]) & df[["img_path"]] != "",
file.path(img.path, df[["img_path"]]),
""
)

# Normalize order: if missing/blank, treat as Inf
df <- df |>
mutate(order = ifelse(is.na(order) | order == "", Inf, as.numeric(order)))

# Get unique committees (excluding NA/empty)
committees <- unique(df$committee)
committees <- committees[!is.na(committees) & committees != ""]

# Process each committee
for(committee_name in committees) {
cat(paste0("\n## ", committee_name, "\n\n"))

# Filter for current committee
df_comm <- df |>
filter(committee == committee_name) |>
arrange(order, name)

# Format each member with image, name, and role
df_comm <- df_comm |>
mutate(
img = sprintf("![](%s){height=150}", img_path),
label = name
img = ifelse(
!is.na(img_path) & img_path != "",
sprintf("![](%s){height=150}", img_path),
""
),
label = ifelse(
!is.na(role) & role != "",
paste0("**", name, "**<br>*", role, "*"),
paste0("**", name, "**")
)
)
n_missing <- ncol - (nrow(df) %% ncol)

# Pad to multiple of ncol
n_missing <- ncol - (nrow(df_comm) %% ncol)
if (n_missing < ncol) {
df <- bind_rows(df, data.frame(
df_comm <- bind_rows(df_comm, data.frame(
name = rep("", n_missing),
local = rep(FALSE, n_missing),
order = rep(Inf, n_missing),
committee = rep("", n_missing),
role = rep("", n_missing),
img_path = rep("", n_missing),
order = rep(Inf, n_missing),
img = rep("", n_missing),
label = rep("", n_missing),
stringsAsFactors = FALSE
))
}

# Make matrix with alternating rows (image row, name row)
img_mtx <- matrix(df$img, ncol = ncol, byrow = TRUE)
name_mtx <- matrix(df$label, ncol = ncol, byrow = TRUE)
img_mtx <- matrix(df_comm$img, ncol = ncol, byrow = TRUE)
name_mtx <- matrix(df_comm$label, ncol = ncol, byrow = TRUE)
ij <- rep(seq_len(nrow(img_mtx)), each = 2) + c(0, nrow(img_mtx))

tbl <- data.frame(rbind(img_mtx, name_mtx)[ij, ])
Expand All @@ -47,4 +83,5 @@ create_organizer_table <- function(table.path = file.path("..", "data", "organiz
print()

cat("\n\n")
}
}
25 changes: 25 additions & 0 deletions data/roles.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name,committee,role
Tuomas Borman,Local,
Tuomas Borman,Community,General member
Leo Lahti,Local,
Leo Lahti,Community,
Helena Crowell,Community,
Maria Doyle,Community,Communications
James Dalgleish,Community,"Partnerships, reviewer "
Michael Stadler,Community,"Scientific program, reviewer"
Annekathrin Nedwed,Community,
Kevin Rue-Albrecht,Community,
Najla Abassi,Community,
Charlotte Soneson,Community,Scientific program
Laurent Gatto,Community,
Robert Castelo,Community,Partnerships
Dario Righelli,Community,
Lena Morrill Gavarro,Community,
Robert Ivánek,Community,
Eliana Ibrahimi,Community,"Scientific program, reviewer"
Lieven Clement,Community,
Federico Marini,Community,
Dania Machlab,Community,Scientific Program
Teemu Daniel Laajala,Local,Partnerships
Julia Mathlin,Local,"Partnerships, Communications"
Nyasita Laurah Ondari,Community,Communications
4 changes: 2 additions & 2 deletions index.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ technologies impacting computational biology.
:::

- **November 24**: Call for abstracts opens
- **January 30**: Call for abstracts closes
- **January 31**: Sticker Design Contest deadline
- <span class="deadline"><strong>January 30</strong>: Call for abstracts closes</span>
- <span class="deadline"><strong>January 31</strong>: Sticker Design Contest deadline</span>
- **June 1-2**: Bioconductor Carpentry Workshops
- **June 3-5**: The EuroBioC2026 Conference!

Expand Down
5 changes: 5 additions & 0 deletions styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -64,3 +64,8 @@ b,strong {
height: 90%;
}

.deadline {
color: #d73027;
font-size: 1.15em;
font-weight: 600;
}
Loading