Learn R Programming

ProfessR (version 2.4-1)

Get.testbank: Get Test Bank From Ascii Text Files

Description

Get Test Bank From Ascii Text Files

Usage

Get.testbank(fn)

Value

List: list of Questions

Arguments

fn

File Name

Author

Jonathan M. Lees<jonathan.lees@unc.edu>

Details

Structure of input file is strict: see the vignette for an example. Each questions starts with the tag QUESTION: (there is a space following the colon on all tags) followed by answers with the correct answer indicated by the tag ANSWER: . The tag FIG: allows the examiner to include a figure with a latex tag for reference. For example: QUESTION: What was the world like during the Late Paleocene Torrid Age? ANSWER: a. Most of the world was wetter and warmer. b. Most of the world was drier and warmer. c. Most of the world was wetter, but a little cooler. d. Most of the world was a desert. e. It is impossible to estimate conditions at that time.

Examples

Run this code

if (FALSE) {
fn = "MY.questions"
Qbank = Get.testbank(fn)

##########  use existing database:
data(QBANK1)
#####  dump out question bank in correct format:
DUMPbank("my.questions", QBANK1, sep = "\n")
###  read it in:
QB1=Get.testbank("my.questions")
}

Run the code above in your browser using DataLab