Code:
$ cat fill2.awk
BEGIN { FS="," ; OFS="," }
{ COLS=NF
for(N=1; N<=NF; N++) D[NR,N]=$N }
END {
for(N=2; N<=COLS; N++)
{
# printf("column %d\n", N);
S=1
for(L=1; L<=NR; L++)
{
if(!D[L,N]) continue;
if(((L-S) < 2) || (!D[S,N]))
{
S=L;
continue;
}
# printf("[%s]", D[S,N]);
SLOPE=(D[L,N]-D[S,N])/(L-S);
for(M=S+1; M<L; M++)
{
X=M-S
D[M,N]=D[S,N]+(SLOPE*X);
# printf("\t'%s'", D[M,N]);
}
# printf("\t[%s]\n", D[L,N]);
S=L;
}
}
for(L=1; L<=NR; L++)
{
printf("%s", D[L, 1]);
for(N=2; N<=COLS; N++) printf(OFS "%s", D[L,N]);
printf("\n");
}
}
$ awk -f fill2.awk data
Wed Feb 01 09:00:02 EST 2012,,,0.4,0.3,,0.3,,0.3,,0.5,,0.3,,,0.4,0.3,
Wed Feb 01 09:00:11 EST 2012,,,0.45,0.35,,0.35,0.2,0.35,,0.55,,0.35,,,0.45,0.35,
Wed Feb 01 09:00:22 EST 2012,0.7,0.4,0.5,0.4,0.3,0.4,,0.4,0.5,0.6,0.3,0.4,,0.1,0.5,0.4,
Wed Feb 01 09:00:42 EST 2012,0.9,1.0,0.6,0.5,0.366667,0.5,,0.433333,0.55,0.625,0.325,0.5,,,0.525,0.425,
Wed Feb 01 09:01:02 EST 2012,1.0,0.8,0.65,0.55,0.433333,0.6,,0.466667,0.6,0.65,0.35,0.6,,,0.55,0.45,
Wed Feb 01 09:01:22 EST 2012,0.95,0.7,0.7,0.6,0.5,,,0.5,0.65,0.675,0.375,0.55,,,0.575,0.475,
Wed Feb 01 09:01:42 EST 2012,0.9,0.6,0.6,0.5,,,,0.4,0.7,0.7,0.4,0.5,,,0.6,0.5,
Wed Feb 01 09:02:02 EST 2012,0.8,,0.5,0.4,,,,1.1,,0.65,0.3,0.4,,,,,
Wed Feb 01 09:02:22 EST 2012,0.9,,,,,,,0.7,,0.6,,,,,,,
$