My Keying (4)

Bug_Dot2Dot

This is a histogram of the duration of spaces when a space is between two dots. The case happens in a single letter, like in “h”, or between two letters like between “n” and “a”.

Bug_Dot2Dash

Spaces between dot and dash, like in a letter “a”, or between the letters like “n” and “n”.

Bug_Dash2Dot

Spaces between dash and dot, like in a letter “n”, or between the letters “a” and “a”.

Bug_Dash2Dash

Spaces between dash and dash, like in a letter “m”, or between the letters “a” and “n”.

BEGIN {
type="null"
val1b4="null"
val2b4=0
val3b4="null"
val1b44=val1b4
val2b44=val2b4
val3b44=val3b4
}

{
 if(val1b44=="dw" && $1=="dw" ) {
  if(val3b44=="long" && $3=="long")
   type="ll"
  if(val3b44=="long" && $3=="short")
   type="ls"
  if(val3b44=="short" && $3=="long")
   type="sl"
  if(val3b44=="short" && $3=="short")
   type="ss"
  print val2b4, type
 }

 val1b44=val1b4
 val2b44=val2b4
 val3b44=val3b4
 val1b4=$1
 val2b4=$2
 val3b4=$3
}
% gawk -f myprog.awk <w3 >w4
% head w3
dw 20 short
up 34 short
dw 105 long
up 98 long
dw 96 long
up 44 long
dw 22 short
up 26 short
dw 24 short
up 28 short
% head w4
34 sl
98 ll
44 ls
26 ss
28 ss
31 ss
156 sl
42 ls
42 sl
37 ls
%R
> th=seq(0,250,10)
> hist(datass$V1,xlim=c(0,250),ylim=c(0,10),breaks=th,main="Dot-to-Dot",col="green")
> hist(datasl$V1,xlim=c(0,250),ylim=c(0,8),breaks=th,main="Dot-to-Dash",col="blue")
> hist(datals$V1,xlim=c(0,250),ylim=c(0,8),breaks=th,main="Dash-to-Dot",col="yellow")
> hist(datall$V1,xlim=c(0,250),ylim=c(0,8),breaks=th,main="Dash-to-Dash",col="red")