The hardware and bandwidth for this mirror is donated by dogado GmbH, the Webhosting and Full Service-Cloud Provider. Check out our Wordpress Tutorial.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]dogado.de.

Title: R Interface to the 'LTP'-Cloud Service
Description: R interface to the 'LTP'-Cloud service for Natural Language Processing in Chinese (http://www.ltp-cloud.com/).
Version: 0.1.4
Author: Tong He [aut, cre], Oliver Keyes [ctb]
Maintainer: Tong He <hetong007@gmail.com>
URL: https://github.com/hetong007/rLTP
BugReports: https://github.com/hetong007/rLTP/issues
Depends: R (≥ 3.3.2), RCurl
License: LGPL-2 | LGPL-2.1 | LGPL-3 [expanded from: LGPL]
LazyData: true
RoxygenNote: 6.0.1
NeedsCompilation: yes
Packaged: 2017-05-29 18:24:46 UTC; tonghe
Repository: CRAN
Date/Publication: 2017-05-29 19:09:05 UTC

rLTP

Description

rLTP


Indicate whether the encoding of input string is BIG5.

Description

Indicate whether the encoding of input string is BIG5.

Usage

isBIG5(string, combine = FALSE)

Arguments

string

A character vector.

combine

Whether to combine all the strings.

Value

A vector of logical values, the length of string - or a single logical value if combine is TRUE.

Author(s)

Jian Li <rweibo@sina.com>


Indicate whether the encoding of input string is GBK.

Description

Indicate whether the encoding of input string is GBK.

Usage

isGB18030(string, combine = FALSE)

Arguments

string

A character vector.

combine

Whether to combine all the strings.

Value

A vector of logical values, the length of string - or a single logical value if combine is TRUE.

Author(s)

Jian Li <rweibo@sina.com>


Indicate whether the encoding of input string is GB18030.

Description

Indicate whether the encoding of input string is GB18030.

Usage

isGB2312(string, combine = FALSE)

Arguments

string

A character vector.

combine

Whether to combine all the strings.

Value

A vector of logical values, the length of string - or a single logical value if combine is TRUE.

Author(s)

Jian Li <rweibo@sina.com>


Indicate whether the encoding of input string is GBK.

Description

Indicate whether the encoding of input string is GBK.

Usage

isGBK(string, combine = FALSE)

Arguments

string

A character vector.

combine

Whether to combine all the strings.

Value

A vector of logical values, the length of string - or a single logical value if combine is TRUE.

Author(s)

Jian Li <rweibo@sina.com>


Indicate whether the encoding of input string is UTF-8.

Description

Indicate whether the encoding of input string is UTF-8.

Usage

isUTF8(string, combine = FALSE)

Arguments

string

A character vector.

combine

Whether to combine all the strings.

Value

A vector of logical values, the length of string - or a single logical value if combine is TRUE.

Author(s)

Jian Li <rweibo@sina.com>


R Interface of LTP-cloud service

Description

This function deals with communication with the server. XML result will be parsed if the mission is word-splitting. Else the raw XML texts will be returned for further analysis.

Usage

ltp(input = NULL, file = NULL, mission = "ws",
  api_key = getOption("ltp_api_key"), maxUpload = 1e+05)

Arguments

input

The input text.

file

The input file.

mission

Expected result for the cloud server, may be unfinished. Optional choices are 'ws' for word-splitting, 'pos' for part-of-speech, 'ner' for named entity recognition, 'dp' for dependency parser, 'srl' for semantic role labeling, 'all' for all missions.

api_key

Your API_Key for the cloud server. Visit http://www.ltp-cloud.com/dashboard/ to get it.

maxUpload

Due to the limitation of the server, we cut the input in pieces.

Examples

## Not run: 
# require(rLTP)
# This api_key is publicly accessible.
# So it is strongly recommended to register for your own key.
# options(ltp_api_key='l2T9N724koSqEcDJvQHtRGVV2erajgPOgB0FAcLj')
# ltp('Replace this field with a Chinese sentence.')

## End(Not run)


Convert encoding of Chinese string to UTF-8.

Description

Convert encoding of Chinese string to UTF-8.

Usage

toUTF8(cnstring)

Arguments

cnstring

A Chinese string vector.

Value

Converted vectors.

Author(s)

Jian Li <rweibo@sina.com>

These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.
Health stats visible at Monitor.