what is diffrence between NROW and nrow in r

0 votes
If nrow and ncol are already present in r, why are they still present? Do they differ from one another or are they merely aliases?

Matrix, mx (1:12,3,4)

nrow(mx)
NROW(mx)

ncol(mx) \sNCOL(mx)
Jun 23, 2022 in Data Analytics by avinash
• 1,840 points
1,354 views

1 answer to this question.

0 votes

5 In R, you may always check the code of a function by entering its name without the quotation marks. By doing this, you can observe how NCOL and ncol differ from one another:

NCOL

function # (x)

If length(d-dim(x)) > 1L, then d[2L] is used. else 1L

#

#

ncol

function # (x)

# dim(x)[2L]

#

#

While NCOL checks to see if the argument only has one dimension, in which case it returns 1, ncol always returns the second dimension of the argument.

Transform data into actionable insights with our Data Analyst Certification – Enroll today!

answered Jun 24, 2022 by Sohail
• 3,040 points

Related Questions In Data Analytics

0 votes
1 answer
0 votes
1 answer

What is the difference between library () and require () functions in R ?

 library() require() Library () function gives an error message ...READ MORE

answered Sep 5, 2018 in Data Analytics by zombie
• 3,790 points
2,775 views
0 votes
2 answers

What is the difference between %% and % in R programming?

HI, %% returns remainder in case of numeric ...READ MORE

answered Aug 26, 2019 in Data Analytics by anonymous
• 33,050 points
2,580 views
0 votes
1 answer

What is the difference between list and vector in R?

The difference are - A list holds different ...READ MORE

answered Oct 29, 2019 in Data Analytics by Cherukuri
• 33,050 points
48,911 views
0 votes
1 answer

Big Data transformations with R

Dear Koushik, Hope you are doing great. You can ...READ MORE

answered Dec 18, 2017 in Data Analytics by Sudhir
• 1,570 points
1,183 views
0 votes
2 answers

Transforming a key/value string into distinct rows in R

We would start off by loading the ...READ MORE

answered Mar 26, 2018 in Data Analytics by Bharani
• 4,660 points
1,449 views
0 votes
1 answer

Finding frequency of observations in R

You can use the "dplyr" package to ...READ MORE

answered Mar 26, 2018 in Data Analytics by Bharani
• 4,660 points
6,023 views
0 votes
1 answer

Left Join and Right Join using "dplyr"

The below is the code to perform ...READ MORE

answered Mar 27, 2018 in Data Analytics by Bharani
• 4,660 points
1,367 views
0 votes
0 answers

What is meant by "An Object" when we use Str() Function in R

Everyone agrees that str() reveals an object's ...READ MORE

Jun 23, 2022 in Data Analytics by avinash
• 1,840 points
460 views
0 votes
0 answers

Is there a quantile function in R that includes both given x and given probs?

I need a R function that computes ...READ MORE

Jun 23, 2022 in Data Analytics by avinash
• 1,840 points
407 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP