Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6248755
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T13:06:57+00:00 2026-05-24T13:06:57+00:00

How can plural nouns be converted into singular nouns using R? I use the

  • 0

How can plural nouns be converted into singular nouns using R? I use the the tagPOS function which tags each text and then extract all of plural nouns which were tagged as “NNS”. But what to do in case I want to convert those plural nouns into singular ones.?


library("openNLP")
library("tm")
acq_o <- "Gulf Applied Technologies Inc said it sold its subsidiaries engaged in pipelines and terminal operations for 12.2 mln dlrs. The company said the sale is subject to certain post closing adjustments, which it did not explain. Reuter."

acq = tm_map(Corpus(DataframeSource(data.frame(acq_o))), removePunctuation)
acqTag <- tagPOS(acq)
acqTagSplit = strsplit(acqTag," ")
qq = 0
tag = 0
for (i in 1:length(acqTagSplit[[1]])){
        qq[i] <-strsplit(acqTagSplit[[1]][i],'/')
        tag[i] = qq[i][[1]][2]
}

index = 0
k = 0
for (i in 1:(length(acqTagSplit[[1]]))) { 
    if (tag[i] == "NNS"){
        k = k +1             
        index[k] = i     
    } 
}
index
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T13:06:58+00:00Added an answer on May 24, 2026 at 1:06 pm

    I’m sure you could pipe your data through an external program, or pre-process your data with it.

    If you’re doing tagging anyway, the German project TreeTagger does a nice job of tagging and lemmatising at the same time.

    EDIT: tchrist was right to remind me that, whatever your purposes, if you’re actually looking for the singular surface forms of your plural nouns, going for a home-baked solution isn’t going to cut it at all.

    And if you don’t then Neo_Me (again, in the comments) seems to have found a package that does stemming in R: the package snowball (RStem seems to have been discontinued. AFAICT, Snowball replaces it.)

    This is just an implementation or wrapper around the Porter stemmer, of course. Use at your own risk, it is going to stem stuff like wives into wif or something like that.

    It just occurred to me, that R has CRAN. Looking for “lemma” there made me aware of the Java-dependent package wordnet. It seems to have a getLemma function. The whole package is likely overkill for you, but might still get you somewhere if you can’t find anything better.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an User(plural) and a Subscription(singular) controllers. I am wondering if I can
How can I make plural/singular words pull all forms? Example: If a person searches
Can someone please provide an example on how to use plural forms in a
How can I add support for plural forms in this Yii class: http://code.google.com/p/yii/source/browse/tags/1.1.8/framework/i18n/gettext/CGettextPoFile.php ?
My project doesn't use the plural convention in table's names. How can I override
I have a number of plural item classes which each have a collection of
Is there any function (VB.NET or C#) that can transform an English word into
Can I get a 'when to use' for these and others? <% %> <%#
I'm using GWT internationalization Messages. The documentation for Plural Forms says this should work:
In my iPhone app, I need to display object counts which I then localize,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.