R/pca.tor.R

"pca.tor" <-
function(data, ... ) {

  data[data < 0]    <- data[data < 0] + 360
  data[data < -180] <- data[data < -180] + 360
  data[data >  180] <- data[data >  180] - 360
  ##cat("Rescaled (-180 to 180) and corrected for periodicity\n")
  data <- wrap.tor(data)
  return( pca.xyz(data, ...) )
}

Try the bio3d package in your browser

Any scripts or data that you put into this service are public.

bio3d documentation built on Oct. 27, 2022, 1:06 a.m.