Running examples in ‘PSCBS-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: segmentByNonPairedPSCBS
> ### Title: Segment total copy numbers and allele B fractions using the
> ###   Non-paired PSCBS method
> ### Aliases: segmentByNonPairedPSCBS.default segmentByNonPairedPSCBS
> ###   segmentByNonPairedPSCBS.data.frame
> ###   segmentByNonPairedPSCBS.PairedPSCBS segmentByNonPairedPSCBS
> ### Keywords: IO
> 
> ### ** Examples
> 
> verbose <- R.utils::Arguments$getVerbose(-10*interactive(), timestamp=TRUE)
> 
> # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> # Load SNP microarray data
> # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> data <- PSCBS::exampleData("paired.chr01")
> str(data)
'data.frame':	73346 obs. of  6 variables:
 $ chromosome: int  1 1 1 1 1 1 1 1 1 1 ...
 $ x         : int  1145994 2224111 2319424 2543484 2926730 2941694 3084986 3155127 3292731 3695086 ...
 $ CT        : num  1.625 1.071 1.406 1.18 0.856 ...
 $ betaT     : num  0.757 0.771 0.834 0.778 0.229 ...
 $ CN        : num  2.36 2.13 2.59 1.93 1.71 ...
 $ betaN     : num  0.827 0.875 0.887 0.884 0.103 ...
> 
> 
> # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> # Paired PSCBS segmentation
> # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> # Drop single-locus outliers
> dataS <- dropSegmentationOutliers(data)
> 
> # Speed up example by segmenting fewer loci
> dataS <- dataS[seq(from=1, to=nrow(data), by=20),]
> 
> str(dataS)
'data.frame':	3668 obs. of  6 variables:
 $ chromosome: int  1 1 1 1 1 1 1 1 1 1 ...
 $ x         : int  1145994 4276892 5034491 6266412 8418532 11211748 13928296 14370144 15014887 16589707 ...
 $ CT        : num  1.63 1.16 1.35 1.39 1.55 ...
 $ betaT     : num  0.7574 0.0576 0.8391 0.7917 0.8141 ...
 $ CN        : num  2.36 2.32 2.33 2.97 2.31 ...
 $ betaN     : num  0.8274 0.0421 0.9406 0.869 0.6045 ...
> 
> R.oo::attachLocally(dataS)
> 
> # Non-Paired PSCBS segmentation
> fit <- segmentByNonPairedPSCBS(CT, betaT=betaT,
+                             chromosome=chromosome, x=x,
+                             seed=0xBEEF, verbose=verbose)
> print(fit)
  chromosome tcnId dhId     start       end tcnNbrOfLoci tcnMean tcnNbrOfSNPs
1          1     1    1    554484 143663981         1880  1.3916          778
2          1     2    1 143663981 185240536          671  2.0925          275
3          1     3    1 185240536 246679946         1111  2.6545          417
  tcnNbrOfHets dhNbrOfLoci    dhMean    c1Mean    c2Mean
1          778         778 0.4009957 0.4167872 0.9748128
2          275         275 0.2344486 0.8009582 1.2915418
3          417         417 0.2819897 0.9529792 1.7015208
> 
> 
> # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> # Bootstrap segment level estimates
> # (used by the AB caller, which, if skipped here,
> #  will do it automatically)
> # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> fit <- bootstrapTCNandDHByRegion(fit, B=100, verbose=verbose)
> print(fit)
  chromosome tcnId dhId     start       end tcnNbrOfLoci tcnMean tcnNbrOfSNPs
1          1     1    1    554484 143663981         1880  1.3916          778
2          1     2    1 143663981 185240536          671  2.0925          275
3          1     3    1 185240536 246679946         1111  2.6545          417
  tcnNbrOfHets dhNbrOfLoci    dhMean    c1Mean    c2Mean
1          778         778 0.4009957 0.4167872 0.9748128
2          275         275 0.2344486 0.8009582 1.2915418
3          417         417 0.2819897 0.9529792 1.7015208
> 
> 
> # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> # Calling segments in allelic balance (AB)
> # NOTE: Ideally, this should be done on whole-genome data
> # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> # Explicitly estimate the threshold in DH for calling AB
> # (which be done by default by the caller, if skipped here)
> deltaAB <- estimateDeltaAB(fit, flavor="qq(DH)", verbose=verbose)
Error in loadNamespace(name) : there is no package called ‘Hmisc’
Calls: estimateDeltaAB ... tryCatch -> tryCatchList -> tryCatchOne -> <Anonymous>
Execution halted