error - /bin/sh: rBuild: command not found

I am very new to R Studio so if this is basic, I apologize. I loaded the appropriate libraries and I am trying to run a decision tree (tree function) but am getting this error message.

I have spent hours on google but can't find anything helpful. Can someone point me in the right direction?

Hi!

To help us help you, could you please prepare a reproducible example (reprex) illustrating your issue? Please have a look at this guide, to see how to create one:

library(tree)
library(party)
library(rpart)
library(rpart.plot)
library(RWeka)

df <- data.frame(stringsAsFactors=FALSE,
label = c(1,2,3,1,2,3,1,2,3,1),
pixel1 = c(1,0,0,1,0,1,0,0,0,1),
pixel2 = c(0,1,0,0,1,0,0,0,0,0),
pixel3 = c(1,4,0,0,1,0,1,0,1,0),
pixel4 = c(0,0,1,0,0,1,0,1,0,1),
pixel5 = c(0,0,1,0,1,0,1,0,1,0))

head(df)

splitPCT <- .25
splitRows <- nrow(df) * splitPCT

dataSplit <- sample(nrow(df), splitRows)
testData <- df[dataSplit,]
dim(testData)

decisionTree <- rpart(label ~ . , data = df, )
dtree1 <- tree(label ~ ., data = df)

decisionTree
dtree1

this runs in a script but I get that error (/bin/sh: rBuild: command not found) in R Studio

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.