Learn R Programming

RPMG (version 2.2-7)

writeCOMMENT: write Code Comments

Description

Create a print out of comments for insertion in computer code. Used for separating important blocks of code with helpful, easy to find comments.

Usage

writeCOMMENT(temp, space = " ", letspace = "", MSUB = "0", prefix = "", suffix = "")

Value

List

26 letters

Arguments

temp

text string

space

space between words

letspace

space between letters

MSUB

text, substitute character, if this is "ALL", then each letter is substituted. default=NULL

prefix

prefix before the letters

suffix

suffix after the letters

Author

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

Details

This is a function used for creating comments in computer code. Letters are a fixed height of 7 lines

Examples

Run this code


 writeCOMMENT("GO TARHEELS", space="      ", letspace = "", MSUB="ALL", prefix="/*" , suffix="*/" )
   writeCOMMENT("START", space="      ", letspace = "", MSUB="ALL", prefix="#######" )
 writeCOMMENT("J M lees", space="      ", letspace = "", MSUB="0" )

 writeCOMMENT("J. M. Lees", space="      ", letspace = "", MSUB="0" )
 writeCOMMENT("J. M. Lees", space="      ", letspace = "", MSUB="." )

writeCOMMENT("J. M. Lees", space="      ", letspace = "" )
writeCOMMENT("J. M. Lees", space="---------", letspace = "" )

writeCOMMENT("J. M. Lees", space="      ", letspace = "", MSUB="ALL" )
writeCOMMENT("J_M_Lees", space="      ", letspace = "", MSUB="ALL" )




  writeCOMMENT("abcdefghi")
writeCOMMENT("jklmnop")

writeCOMMENT("qrstuvwxyz")
writeCOMMENT("1234567890")
writeCOMMENT("WHY?!.-+=_")
writeCOMMENT("2+2=4")
writeCOMMENT("e*exp(pi*i)=-1")





Run the code above in your browser using DataLab