@@ -78,7 +78,7 @@ summarizePedigrees <- function(ped,
7878 )
7979 }
8080 if (! is.null(founder_sort_var ) &&
81- ! founder_sort_var %in% names(ped )) {
81+ ! founder_sort_var %in% names(ped )) {
8282 stop(
8383 " If you set founder_sort_var, that variable must be a column in the pedigree data. If you want to sort by using the default, set founder_sort_var = NULL. The default is to sort by birth year if that's present and by personID otherwise."
8484 )
@@ -265,7 +265,7 @@ summarizePedigrees <- function(ped,
265265 )
266266 }
267267 }
268- return ( output )
268+ output
269269}
270270
271271
@@ -316,7 +316,7 @@ calculateSummaryDT <- function(data,
316316 ]
317317 # Flatten the nested lists
318318 summary_stats <- data.table :: as.data.table(summary_stats [, lapply(.SD , unlist ), by = group_var ])
319- return ( summary_stats )
319+ summary_stats
320320}
321321
322322# ' Function to find the originating member for each line
@@ -363,7 +363,7 @@ summarizeFounder <- function(ped_dt,
363363 by = group_var ,
364364 suffixes = c(" " , " _founder" )
365365 )
366- return ( foo_summary_dt )
366+ foo_summary_dt
367367}
368368
369369
@@ -392,7 +392,7 @@ findFooest <- function(foo_summary_dt,
392392 }
393393 ))
394394
395- return ( subset_foo )
395+ subset_foo
396396}
397397
398398# ' Function to find the oldest individuals in a pedigree
@@ -414,7 +414,7 @@ findOldest <- function(foo_summary_dt,
414414 n_fooest = n_fooest ,
415415 decreasing = FALSE
416416 )
417- return ( oldest_foo )
417+ oldest_foo
418418}
419419
420420# ' Function to find the biggest families in a pedigree
@@ -436,7 +436,7 @@ findBiggest <- function(foo_summary_dt,
436436 n_fooest = n_fooest ,
437437 decreasing = TRUE
438438 )
439- return ( biggest_foo )
439+ biggest_foo
440440}
441441
442442# ' Function to prepare the pedigree for summarization
@@ -492,7 +492,7 @@ prepSummarizePedigrees <- function(ped,
492492 }
493493
494494
495- return ( ped )
495+ ped
496496}
497497
498498# ' Function to summarize the oldest individuals in a pedigree
@@ -548,5 +548,5 @@ summarizeOldest <- function(byr = NULL,
548548 )
549549 }
550550 }
551- return ( output )
551+ output
552552}
0 commit comments