sync                  package:Rsac                  R Documentation

_S_Y_N_C_H_R_O_N_I_Z_E

_D_e_s_c_r_i_p_t_i_o_n:

     Synchronizes the reference times of all files in a vector of SAC
     files. This is done automatically in 'plot.rsac'. This is useful
     if you are sending each file to a different plot but want the
     relative time to be consistent between the different plots.

_U_s_a_g_e:

     sync(x)

_A_r_g_u_m_e_n_t_s:

       x: an object of class '"rsac"'.

_V_a_l_u_e:

     same as input.

_A_u_t_h_o_r(_s):

     Eric M. Thompson <eric.thompson@tufts.edu>

_S_e_e _A_l_s_o:

     'plot.rsac'

_E_x_a_m_p_l_e_s:

     data(srosa)

     # Misleading, because t0 is different for each 
     # trace:
     par(mfrow = c(3, 1), mar = c(3,4,1,1))
     xlim = c(0, 400)
     plot(srosa[1], axes = FALSE, ylab = "z",
          xlab = "", xlim = xlim)
     axis(side = 2); axis(side = 1)
     plot(srosa[2], axes = FALSE, ylab = "North-South",
          xlab = "", xlim = xlim)
     axis(side = 2); axis(side = 1)
     plot(srosa[3], axes = FALSE, ylab = "East-West",
          xlab = "Time", xlim = xlim)
     axis(side = 2); axis(side = 1)

     # Better:
     srosa <- sync(srosa)
     par(mfrow = c(3, 1), mar = c(3,4,1,1))
     xlim = c(0, 400)
     plot(srosa[1], axes = FALSE, ylab = "z",
          xlab = "", xlim = xlim)
     axis(side = 2)
     plot(srosa[2], axes = FALSE, ylab = "North-South",
          xlab = "", xlim = xlim)
     axis(side = 2)
     plot(srosa[3], axes = FALSE, ylab = "East-West",
          xlab = "Time", xlim = xlim)
     axis(side = 2); axis(side = 1)

