Learn R Programming

bdpar (version 1.0.1)

FindUserNamePipe: Class to find and/or remove the users on the data field of an Instance

Description

This class is responsible of detecting the existing use names in the data field of each Instance. Identified user names are stored inside the userName field of Instance class. Moreover if required, is able to perform inline user nanme removement.

Usage

FindUserNamePipe

Arguments

Constructor

FindUserNamePipe$new(propertyName = "userName",
                     alwaysBeforeDeps = list(),
                     notAfterDeps = list())

  • Arguments:

    • propertyName: (character) name of the property associated with the Pipe.

    • alwaysBeforeDeps: (list) the dependences alwaysBefore (Pipes that must be executed before this one).

    • notAfterDeps: (list) the dependences notAfter (Pipes that cannot be executed after this one).

Inherit

This class inherits from PipeGeneric and implements the pipe abstract function.

Methods

  • pipe: preprocesses the Instance to obtain/remove the name users.

    • Usage: pipe(instance, removeUser = TRUE)

    • Value: the Instance with the modifications that have occurred in the Pipe.

    • Arguments:

      • instance: (Instance) Instance to preproccess.

      • removeUser: (logical) indicates if the users are removed.

  • findUserName: finds the name users in the data.

    • Usage: findHashtag(data)

    • Value: list with users names found.

    • Arguments:

      • data: (character) text to search the user names.

  • removeUserName: removes the users in the data.

    • Usage: removeUserName(data)

    • Value: the data with name users removed.

    • Arguments:

      • data: (character) text to remove the user names.

Public fields

  • userPattern: (character) regular expression to detect users.

Details

The regular expressions indicated in the userPattern variable are used to identify user names.

See Also

AbbreviationPipe, ContractionPipe, File2Pipe, FindEmojiPipe, FindEmoticonPipe, FindHashtagPipe, FindUrlPipe, GuessDatePipe, GuessLanguagePipe, Instance, InterjectionPipe, MeasureLengthPipe, PipeGeneric, SlangPipe, StopWordPipe, StoreFileExtPipe, TargetAssigningPipe, TeeCSVPipe, ToLowerCasePipe