Welcome to Code Sharer, a code gallery for creating, saving and sharing all kinds of code snippets.

R — Heart Graph

Posted On: Tuesday, December 2, 2014 at 11:27 AM Last updated: Wednesday, May 9, 2018 at 12:25 PM

"lwd" is the width of the line
Heart R plot
t<- seq(from=0.01,to=10,by=0.0001)
x<- 16*sin(t)^(3)
y<- 13*cos(t)-5*cos(2*t)-2*cos(3*t)-cos(4*t)
plot(x,y, type="l", col="pink", lwd=10)

Snip Comments

ADMIN Ewan says Monday, January 9, 2017 at 11:03 AM

Love this. - If you mind the pun. 

Saira says Tuesday, May 9, 2017 at 7:12 AM

Love it! i'm going to try it!

Ryan Bradley-Evans (Admin)

Joined on
Contributed 16 Snips

Get Social and Share