Trending questions in Data Analytics

0 votes
9 answers

Creating an empty data.frame with only column names - R

Will the below code work to create ...READ MORE

Aug 1, 2019 in Data Analytics by preeti
23,568 views
0 votes
4 answers

Printing a data.frame without index - Python

.tolist() function will remove index READ MORE

Mar 11, 2019 in Data Analytics by nishant thakur
21,654 views
+1 vote
0 answers

Counting the frequency of user activities - R

Within a data frame (see below), I ...READ MORE

Dec 3, 2019 in Data Analytics by anonymous
• 130 points
113 views
+1 vote
1 answer

Why data cleaning plays a vital role in the analysis?

Data cleaning is the fourth step in ...READ MORE

Nov 22, 2019 in Data Analytics by Keshav
110 views
0 votes
1 answer

What is the difference between list and vector in R?

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

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
1,328 views
0 votes
1 answer

Error in unique.default(x, nmax = nmax) : unique() applies only to vectors in R

This error is displayed if you used ...READ MORE

Oct 30, 2019 in Data Analytics by Cherukuri
• 32,420 points
407 views
+9 votes
1 answer

Will random forest algorithm work if rows have a few duplicate values?

I have no idea about RandomForest, but ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
97 views
0 votes
1 answer

What is grob and how to create grobs in ggplot?

A grid graphical object (“grob”) is a ...READ MORE

Oct 29, 2019 in Data Analytics by Cherukuri
• 32,420 points
155 views
0 votes
1 answer

Splitting strings in a list delimited by space

Use strspltit function and provide separator as ...READ MORE

Oct 30, 2019 in Data Analytics by Cherukuri
• 32,420 points
98 views
0 votes
1 answer

How to add layers in ggplot?

You can add multiple layers with one ...READ MORE

Oct 31, 2019 in Data Analytics by Cherukuri
• 32,420 points
46 views
0 votes
1 answer

Add image background to ggplot

I found this way from a blog. Check ...READ MORE

Oct 31, 2019 in Data Analytics by Cherukuri
• 32,420 points
38 views
0 votes
1 answer

How to arrange ggplots in custom order?

You can arrange a ggplot by using ...READ MORE

Oct 29, 2019 in Data Analytics by Cherukuri
• 32,420 points
61 views
0 votes
1 answer

unable to install reprtree package

The solution to the same issue is ...READ MORE

Nov 2, 2019 in Data Analytics by Cherukuri
• 32,420 points
111 views
0 votes
1 answer

Error: `width` is shorter than `ellipsis`FALSE

Add ellipsis = "" attribute to remove ...READ MORE

Oct 29, 2019 in Data Analytics by Cherukuri
• 32,420 points
40 views
0 votes
1 answer

What is the difference between merge and bind in R?

Merge function merges an arbitrarily large series ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
153 views
0 votes
1 answer

Edit list elements when condition is met

You can use regular if condition with ...READ MORE

Oct 31, 2019 in Data Analytics by Cherukuri
• 32,420 points
30 views
0 votes
1 answer

How to use hclust function?

hclust performs hierarchical cluster analysis on a ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
67 views
0 votes
1 answer

Intermediate + running sum of vector

Hey, It's quite simple, use the accumulate function ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
36 views
0 votes
1 answer

Add list elments recursively

You cannot use the sum function on ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
34 views
0 votes
1 answer

Truncate numeric values without round off

You can either use substring function or ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
30 views
0 votes
1 answer

What is a regex?

A regular expression, regex or regexp is ...READ MORE

Nov 2, 2019 in Data Analytics by Cherukuri
• 32,420 points
27 views
0 votes
1 answer

How to use regular expressions in R?

Set of operators to use for regular ...READ MORE

Nov 2, 2019 in Data Analytics by anonymous
• 32,420 points
23 views
0 votes
1 answer

How do I remove an element from a list by index in R?

Use list[index] = NULL The list value will ...READ MORE

Oct 31, 2019 in Data Analytics by Cherukuri
• 32,420 points
55 views
0 votes
1 answer

How to combine 2 fields in a dataframe to create a new field?

Use paste command or append function to ...READ MORE

Oct 31, 2019 in Data Analytics by Cherukuri
• 32,420 points
25 views
0 votes
1 answer

How to check if a file already exists or not in R?

Check out file.exists() function!! The function file.exists() returns a ...READ MORE

Oct 29, 2019 in Data Analytics by Cherukuri
• 32,420 points
81 views
0 votes
1 answer

Create a new string from existing strings in different variables

Its quite simple, Use paste function as ...READ MORE

Oct 31, 2019 in Data Analytics by Cherukuri
• 32,420 points
22 views
0 votes
1 answer

Slicing a list using an index vector in r

Use index within [] and provide an ...READ MORE

Nov 2, 2019 in Data Analytics by Cherukuri
• 32,420 points
84 views
0 votes
1 answer

How to check if a element is present in the list?

There are multiple functions for this purpose ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
38 views
0 votes
1 answer

How to find cumulative total of rows in r?

Calculate intermediate sum and total sum using ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
28 views
0 votes
1 answer

How does paste function work in R?

Paste function concatenates vectors together. Syntax: paste(v1,v2,sep = ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
42 views
0 votes
1 answer

How to convert continuous variable to categorical variable and vice versa?

Use discretize function to convert a continuous variable ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
40 views
0 votes
1 answer

How to check installed packages from r source?

Use installed.packages() or find.package() function and pass the ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
39 views
0 votes
1 answer

Do we need to create vectors to create arrays in R?

Yes, you need vectors to create arrays. Arrays take vectors in ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
25 views
0 votes
1 answer

How to set data type of columns while reading from source?

@ch, Add colClasses attribute to read the statement ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
26 views
0 votes
1 answer

How to create a range of dates in R?

Hey, See the below example, > superstore$Order.Date[1] [1] "2014-11-11" > seq(superstore$Order.Date[1],length.out ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
22 views
0 votes
1 answer

List should be atomic

@ch, A few functions only work with an ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
23 views
0 votes
1 answer

plot function - hide x/y - axis points

hey @ch, Use the below attribute to hide ...READ MORE

Oct 21, 2019 in Data Analytics by Cherukuri
• 32,420 points
44 views
0 votes
1 answer

what is a contingency table?

A contingency table is a table showing ...READ MORE

Oct 21, 2019 in Data Analytics by Cherukuri
• 32,420 points
44 views
0 votes
0 answers

How to convert a table into tree?

I used getTree() and randomForest object to ...READ MORE

Oct 22, 2019 in Data Analytics by ch
• 3,380 points
32 views
0 votes
1 answer

Convert a contingency table into dataframe

The simplest way to convert the contingency ...READ MORE

Oct 21, 2019 in Data Analytics by Cherukuri
• 32,420 points
34 views
0 votes
1 answer

How to create a weighted data set?

HI @ch, Create a list of elements and ...READ MORE

Oct 21, 2019 in Data Analytics by Cherukuri
• 32,420 points
32 views
0 votes
1 answer

plot function - hide all ticks

hey @ch, Use below attribute to hide all ...READ MORE

Oct 21, 2019 in Data Analytics by Cherukuri
• 32,420 points
31 views
0 votes
0 answers

How to visualize the randomForest model in R?

How to visualize the randomForest model in ...READ MORE

Oct 22, 2019 in Data Analytics by ch
• 3,380 points
22 views
0 votes
1 answer

Manage length of field values

Hi, Use str_pad() function to format the length ...READ MORE

Oct 23, 2019 in Data Analytics by Cherukuri
• 32,420 points
29 views
0 votes
1 answer

Error "Object Concentration not found"

Hi Sanju, is the abc data frame created in ...READ MORE

Oct 18, 2019 in Data Analytics by Cherukuri
• 32,420 points
32 views
0 votes
1 answer

How to create heat maps in R?

Use heatmap() to create heatmaps. > heatmap(as.matrix(mtcars)) See below ...READ MORE

Oct 28, 2019 in Data Analytics by Cherukuri
• 32,420 points
25 views
0 votes
2 answers

How to sum a variable by group in R?

You can also try this way, x_new = ...READ MORE

Jul 31, 2019 in Data Analytics by Cherukuri
• 32,420 points
13,607 views
0 votes
1 answer

What are the different ways to manage NA's in data?

A few functions to manage NA are ...READ MORE

Oct 16, 2019 in Data Analytics by Cherukuri
• 32,420 points
56 views
0 votes
1 answer

How to find the difference wrt previous value in list/vector?

diff() function returns the difference between numbers ...READ MORE

Oct 16, 2019 in Data Analytics by Cherukuri
• 32,420 points
35 views