Learn R Programming

RQDA (version 0.1-6)

Deletion: Functions for dealing with the temporarily deleted data

Description

list.deleted shows the temporarily deleted data (deleted by delete button, which is only tagged with deletion mark in the *.rqda file). pdelete permanently deletes them. CleanProject cleans the *.rqda file (call pdelete with every possible value for the type argument). undelete removes the temporarily deletion mark to reuse the temporarily deleted data.

Usage

list.deleted(type=c("file","code","case","codecategory","filecategory"))
pdelete(type=c("file","code","case","codecategory","filecategory","coding"),ask=FALSE)
CleanProject(ask=FALSE)
undelete(type=c("file","code","case","codecategory","filecategory"),ask=TRUE)

Arguments

type
Types of elements in the *.rqda file. "file" is the name of file (in the Files Tab). "code" is the name of codes (in the Codes Tab). "case" is the name of case (in the Case Tab). "codecategory" is name of code category (in the C-Cat Tab). "fileca
ask
You can choose which ones to be deleted when is TRUE. Otherwise, it will delete all with temporarily deletion mark.

Value

  • For list.deleted, a data frame if there are some records with temporarily deletion mark for the specified type. For pdelete, CleanProject and undelete, no value is return. These functions are used for the side-effects.

Details

By GUI, you can delete file, code, case, code category and file categroy. When click the delete button, the status of related elements (e.g. for file, the elements includ file, related coding, related case category and file category) are set from 1 to 0. In this sense, deletion from GUI is temporary. After that, you can use list.deleted to show which ones are tagged as deleted. By pdelete, you can permenantly delete those tagged with temporarily deletion mark. By undelete, you can undo the temporary deletion, the status of related elements are set back to 1. When ask is FALSE, it will apply to all the propriate elements of specific type. When it is TRUE, you can choose the elements of the specific type which the action (pdelet or undelete) applies to.