Skip to content

Commit

Permalink
plot log of data instead of rescaling axis
Browse files Browse the repository at this point in the history
  • Loading branch information
pcp135 committed Sep 16, 2012
1 parent 50d8046 commit e7c134a
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions 03-Classification/email_classify.R
Original file line number Diff line number Diff line change
Expand Up @@ -302,11 +302,9 @@ class.df$Class <- as.logical(as.numeric(class.df$Class))
class.df$Type <- as.factor(class.df$Type)

# Create final plot of results
class.plot <- ggplot(class.df, aes(x = Pr.HAM, Pr.SPAM)) +
class.plot <- ggplot(class.df, aes(x = log(Pr.HAM), log(Pr.SPAM))) +
geom_point(aes(shape = Type, alpha = 0.5)) +
stat_abline(yintercept = 0, slope = 1) +
scale_x_log10() +
scale_y_log10() +
scale_shape_manual(values = c("EASYHAM" = 1,
"HARDHAM" = 2,
"SPAM" = 3),
Expand Down

0 comments on commit e7c134a

Please sign in to comment.