What do you want to save?
Add Code snippet
New code examples
-
Python 2022-03-19 17:05:11
ggplot2 histogram
library(ggplot2) # Basic histogram ggplot(df, aes(x=weight)) + geom_histogram() # Change the width of bins ggplot(df, aes(x=weight)) + geom_histogram(binwidth=1) # Change colors p<-ggplot(df, aes(x=weight)) + geom_histogram(color="black"... Add solution -
Python 2022-03-17 06:25:01
matplotlib embedded in tkinter
# Creates simple Graph embedded in tkinter import tkinter from tkinter import * import numpy as np from matplotlib.backends.backend_tkagg import FigureCanvasTkAgg, NavigationToolbar2Tk from matplotlib.figure import Figure tkFenster = Tk() tkFenster.geom... Add solution -
Other 2022-03-16 23:10:27
show equation using geom_smooth
library(ggpmisc) df <- data.frame(x = c(1:100)) df$y <- 20 * c(0, 1) + 3 * df$x + rnorm(100, sd = 40) df$group <- factor(rep(c("A", "B"), 50)) my.formula <- y ~ x p <- ggplot(data = df, aes(x = x, y = y, colour = group))... Add solution -
R 2022-03-16 11:05:16
ggplot box plot without outliers poins
p + geom_boxplot(outlier.shape=NA) Add solution -
Python 2022-03-13 04:10:03
Circular heatmap python
from pylab import * import numpy as np from scipy.interpolate import griddata #create 5000 Random points distributed within the circle radius 100 max_r = 100 max_theta = 2.0 * np.pi number_points = 5000 points = np.random.rand(number_points,2)*[max_r,max... Add solution -
Python 2022-03-12 07:00:02
how to find the labels of the confusion matrix in python
""" In order to find the labels just use the Counter function to count the records from y_test and then check row-wise sum of the confusion matrix. Then apply the labels to the corresponding rows using the inbuilt seaborn plot as shown b... Add solution