function [sum_f, sum_g, meansq_f, meansq_g, snr] = seq_snr(f,g)
% SEQ_SNR(A,B) returns a row vector with SNR parameters based
% on row vectors A and B.

N = length(f);

sum_f = sum(f);
sum_g = sum(g);
meansq_f = sum(abs(f).^2)/N;
meansq_g = sum(abs(g).^2)/N;

product_meansq = meansq_f * meansq_g;
identity = pcorr(f,g);
top = identity(1).^2;
snr = top/product_meansq;