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)

