Hi, > How can I get R to insert such line into the head section > of html file being generated under hwriter?
I found an answer myself. It turns out that the line <link rel="stylesheet" type="text/css" href="hwriter.css"></link> doesn't have to go into body section. As an experiment, I did: p = openPage ('testPage.html') hwrite ('<link rel="stylesheet" type="text/css" href="hwriter.css"></link>', p) hwrite (iris[1:3,1:3], p, row.bgcolor='#ffda99') closePage (p) browseURL ('testPage.html') and I get what I wanted. If you have a better/different idea, I'd love to hear it. Regards, Tena Sakai tsa...@gallo.ucsf.edu -----Original Message----- From: r-help-boun...@r-project.org on behalf of Tena Sakai Sent: Thu 4/30/2009 3:56 PM To: r-help@r-project.org Subject: [R] newbie HWRITER package question Hi, I am playing with hwriter examples given in "example" page. Here's what I've done: > library (hwriter) > > p = openPage ('table.html') > hwrite (1:5, p) > hwrite (iris[1:3, 1:3], p, row.bgcolor='#ffdc98') > closePage (p) > > browseURL('table.html') What I get is not as nice as what I see via the "example" page. I looked at the html source for the example page and got a notion maybe I should stick this line between <head> and </head>: <link rel="stylesheet" type="text/css" href="hwriter.css"></link> (I had copied this file into the current working directory.) and bingo! Yeeehaa! My page suddenly looks so much nicer! So, here's today's newbie quesion: How can I get R to insert such line into the head section of html file being generated under hwriter? I would appreciate your guidance. Thank you. Regards, Tena Sakai tsa...@gallo.ucsf.edu [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.