|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectScanningKeyboardSPC
public class ScanningKeyboardSPC
java ScanningKeyboardSPC file -ak|-kk|ck... [-wfs] [kl] [-spc] [-wp] [-hh] where file = word-frequency dictionary file -ak = alpha keyboard layout (_abcde-fghijk-lmnopq-rstuvw-xyz...) -kk = Koester-Levine keyboard layout (_eardu-tnsfwb-ohcpvj-imkkq.-lgxz..) -ck... = custom keyboard layout (e.g., -ck_ABCD-EFGHI-KLMNO-PQRST-WXYZ~) -wfs = output word-freq-scans -kl = output keyboard layout -spc = output Scan Steps Per Characters statistic -wp = word predict (use "W" (uppercase) in layout to indicate column) -hh = assume half-and-half scanning for word prediction
The first argument is a word-frequency dictionary. This is a reduced version of the language corpus used for the analysis. For the analyses in the first reference above, three such word-frequency files were used: d1-wordfreq.txt, d2-wordfreq.txt, bc-wordfreq.txt, and phrases2-wordfreq.txt. Consult the first reference above for details on the original corpora.
Optional arguments appear next.
The -ak
and -kk
options are used for two layouts that are hard-coded in
the application. These are an alphabetic layout (-ak
option) and an optimized layout
proposed in the Koester and Levine reference (-kk
option). See below.
ALPHABETIC KOESTER-LEVINE =========== =========== _ a b c d e _ e a r d u f g h i j k t n s f w b l m n o p q o h c p v j r s t u v w i m y k q . x y z . . . l g x z . .
An underscore ("_
") represents the SPACE character. Periods (".") are unassigned
keys.
The -ck
option is used to specify a custom layout. A dash is used as a row
separator. There must be an equal number of characters per row. Use lowercase letters. See
example invocations below.
There are three output options:
-wfs
– output the word-frequency list; each line is appended with the
coded scan steps for the word
-kl
– output the keyboard layout
-spc
– output the computed scan steps per character (SPC)
The -wp
option is for word prediction. This option is used for keyboards that
include a dedicated column for words. The word entries are identified by W (uppercase) in the
column where the words appear. Words are predicted from the current word stem and are assumed to
populate the word list after each character entered. Words are sorted by their probability in the
word-frequency file. The computation of SPC will consider the contents of this list for optimal
input (i.e., lowest SPC).
The -hh
option is for "half-and-half scanning", as proposed by Koester and Levine.
This option only applies if the -wp
option is also used. Half-and-half-scanning is
used to speed-up entry with word prediction. Scanning initially alternates between the
letter-region and the word-region of the keyboard. The user first selects in the desired region,
then selects within the letter or word region of the keyboard. Within the letter region,
conventional row-column scanning is used.
PROMPT>java ScanningKeyboardSPC d1-wordfreq.txt -ak -spc -kl Scanning keyboard layout... _ a b c d e f g h i j k l m n o p q r s t u v w x y z . . . WordFreqFile=d1-wordfreq.txt, SPC = 5.19 PROMPT>java ScanningKeyboardSPC d1-wordfreq.txt -kk -spc -kl Scanning keyboard layout... _ e a r d u t n s f w b o h c p v j i m y k q . l g x z . . WordFreqFile=d1-wordfreq.txt, SPC = 4.28 PROMPT>java ScanningKeyboardSPC d1-wordfreq.txt -kk -wfs the 5776384 .Rt..R.hR.eR_ of 2789403 ..Ro.R...fR_ and 2421302 R..a.R.nR....dR_ a 1939617 R..aR_ in 1695860 ...Ri.R.nR_ to 1468146 .Rt..RoR_ is 892937 ...Ri.R..sR_ ... PROMPT>java ScanningKeyboardSPC d1-wordfreq.txt -ck_abcd-efghi-jklmn-opqrs-tuvwx-yz... -kl -spc Keyboard layout... _ a b c d e f g h i j k l m n o p q r s t u v w x y z . . . WordFreqFile=d1-wordfreq.txt, SPC = 5.14 PROMPT>java ScanningKeyboardSPC d1-wordfreq.txt -ck_earduW-tnsfwbW-ohcpvjW-imykq.W-lgxz..W-......W -kl -spc -wp Keyboard layout... _ e a r d u W t n s f w b W o h c p v j W i m y k q . W l g x z . . W . . . . . . W WordFreqFile=d1-wordfreq.txt, SPC= 3.35 PROMPT>java ScanningKeyboardSPC d1-wordfreq.txt -ck_earduW-tnsfwbW-ohcpvjW-imykq.W-lgxz..W-......W -kl -spc -wp -hh Keyboard layout... _ e a r d u W t n s f w b W o h c p v j W i m y k q . W l g x z . . W . . . . . . W WordFreqFile=d1-wordfreq.txt, SPC= 2.73The last two invocations are examples with word prediction. The word prediction list is included as an extra column in the layout. Uppercase
W
indicates the column. As proposed by Koester and Levine, there are six words in the list, so an
extra row is added. Note the reduced SPC with half-and-half scanning, from SPC = 3.35 to SPC =
2.73.
Obviously, the command-line arguments are long and complicated when doing analyses on keyboards with custom layouts. One approach is to organize the analyses in a batch file. As an example, the batch file ScanningKeyboardSPC.bat was used to generate the analyses used in the MacKenzie ICCHP 2012 paper.
A separate application called WordPredict
is available to view the word prediction lists,
if desired.
Constructor Summary | |
---|---|
ScanningKeyboardSPC()
|
Method Summary | |
---|---|
static int |
getColumnIndex(char[][] keyboardArg,
char cArg)
|
static int |
getRowIndex(char[][] keyboardArg,
char cArg)
|
static java.lang.String |
getScans(char[][] keyboardArg,
java.lang.String wordArg,
WordPredict wpArg,
boolean hhOptionArg)
|
static void |
main(java.lang.String[] args)
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ScanningKeyboardSPC()
Method Detail |
---|
public static void main(java.lang.String[] args) throws java.io.IOException
java.io.IOException
public static int getRowIndex(char[][] keyboardArg, char cArg)
public static int getColumnIndex(char[][] keyboardArg, char cArg)
public static java.lang.String getScans(char[][] keyboardArg, java.lang.String wordArg, WordPredict wpArg, boolean hhOptionArg)
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |