annotate generateIcon.R @ 75:279cf9b11c73

logo generation code
author matthiasm
date Fri, 29 Nov 2013 13:46:12 +0000
parents
children df8784695584
rev   line source
matthiasm@75 1 t <- seq(0,8*pi,.01)
matthiasm@75 2 w <- pnorm(t, 4*pi, 1)
matthiasm@75 3 n <- length(t)
matthiasm@75 4 pitchDiff <- 6
matthiasm@75 5 sin1 <- sin(t) + pitchDiff
matthiasm@75 6 sin2 <- sin(t)
matthiasm@75 7
matthiasm@75 8 lineWidth <- 15
matthiasm@75 9 outlineWidth <- 20
matthiasm@75 10 sz <- 200
matthiasm@75 11
matthiasm@75 12 png("tonyLogoWave.png", width = sz, height = sz)
matthiasm@75 13 par(mar=c(0,0,0,0))
matthiasm@75 14 plot(t, sin1 * w + sin2 * (1-w), type='l',
matthiasm@75 15 lwd=lineWidth, bty='n', xaxt='n', yaxt='n',
matthiasm@75 16 ylim = c(-2, pitchDiff+2) + c(1,-1)*0.1,
matthiasm@75 17 xlim = c(0, 8*pi) + c(1,-1)*0.1)
matthiasm@75 18 lines(c(0,0),c(-2,pitchDiff+2), lwd=outlineWidth, col = 'blue', lend=2)
matthiasm@75 19 lines(c(0,0)+8*pi,c(-2,pitchDiff+2), lwd=outlineWidth, col = 'blue', lend=2)
matthiasm@75 20 lines(c(0,8*pi),c(0,0)+pitchDiff+2, lwd=outlineWidth, col = 'blue', lend=2)
matthiasm@75 21 lines(c(0,8*pi),c(0,0)-2, lwd=outlineWidth, col = 'blue', lend=2)
matthiasm@75 22 dev.off()