Well never mind I found a way.
heat_tree
legend_break = factor(c("0", "1-100", "100-400", "400-500", "500-600", "600-700", "700-800", "800-9000"))
legend_data<-data.frame(order=1:8,legend_break )
heat_tree + geom_point(data = legend_data,
aes(x = 1, y = 1, color = legend_break),
shape = 15, # shape 15 gives a square
size = 6, alpha = 0,
show.legend = TRUE) +
scale_color_manual(name = "N of sequences", # Add legend title here
values = c("#FF0000",
"#D3D3D3",
"#BBDF27",
"#76CD52",
"#54C568",
"#46AB74",
"#389181",
"#2A788E")) +
guides(color = guide_legend(override.aes = list(alpha = 1, shape = 15, size = 7))) +
theme(legend.position = c(1, 1),
legend.justification = c(1, 1),
legend.text = element_text(size = 10),
legend.title = element_text(size = 10),
legend.key.size = unit(0.3, "cm"),
legend.spacing = unit(0.2, "cm"))