<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Scienco.org &#187; Uncategorized</title>
	<atom:link href="http://www.scienco.org/category/uncategorized/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.scienco.org</link>
	<description>Life&#039;s too short to be unenthusiastic</description>
	<lastBuildDate>Thu, 07 Jul 2011 13:47:55 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
	<atom:link rel="next" href="http://www.scienco.org/category/uncategorized/feed/?page=2" />

		<item>
		<title>(Ugly) custom case for Amazon Kindle 3rd generation</title>
		<link>http://www.scienco.org/2010/ugly-custom-case-for-amazon-kindle-3rd-generation/</link>
		<comments>http://www.scienco.org/2010/ugly-custom-case-for-amazon-kindle-3rd-generation/#comments</comments>
		<pubDate>Thu, 30 Sep 2010 12:20:04 +0000</pubDate>
		<dc:creator>Mikkel Meyer Andersen</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Kindle]]></category>

		<guid isPermaLink="false">http://www.scienco.org/?p=271</guid>
		<description><![CDATA[At couple of days ago I got my Amazon Kindle ($139, 3rd gen.). So far I'm really happy with it! While buying it, I decided that the cases were too expensive compared to the device. So I decided to make one myself. And as suspected, there was no happy end in that story. So hopefully the [...]]]></description>
			<content:encoded><![CDATA[<p>At couple of days ago I got my Amazon Kindle ($139, 3rd gen.). So far I'm really happy with it! While buying it, I decided that the cases were too expensive compared to the device. So I decided to make one myself. And as suspected, there was no happy end in that story. So hopefully the Amazon guys will read this post and view the pictures. And pity me. But the device itself is awesome and I enjoy using it. Only a couple of objections:</p>
<ul>
<li>Come on: use an open e-book format</li>
<li>Support a library loan function (I know it's against your business as such, but it would be nice)</li>
</ul>
<p>And the pictures:<br />

<a href='http://www.scienco.org/2010/ugly-custom-case-for-amazon-kindle-3rd-generation/dsc_5606/' title='DSC_5606'><img width="150" height="150" src="http://www.scienco.org/wp-content/DSC_5606-150x150.jpg" class="attachment-thumbnail" alt="DSC_5606" title="DSC_5606" /></a>
<a href='http://www.scienco.org/2010/ugly-custom-case-for-amazon-kindle-3rd-generation/dsc_5603/' title='DSC_5603'><img width="150" height="150" src="http://www.scienco.org/wp-content/DSC_5603-150x150.jpg" class="attachment-thumbnail" alt="DSC_5603" title="DSC_5603" /></a>
<a href='http://www.scienco.org/2010/ugly-custom-case-for-amazon-kindle-3rd-generation/dsc_5602/' title='DSC_5602'><img width="150" height="150" src="http://www.scienco.org/wp-content/DSC_5602-150x150.jpg" class="attachment-thumbnail" alt="DSC_5602" title="DSC_5602" /></a>
<a href='http://www.scienco.org/2010/ugly-custom-case-for-amazon-kindle-3rd-generation/dsc_5601/' title='DSC_5601'><img width="150" height="150" src="http://www.scienco.org/wp-content/DSC_5601-150x150.jpg" class="attachment-thumbnail" alt="DSC_5601" title="DSC_5601" /></a>
<a href='http://www.scienco.org/2010/ugly-custom-case-for-amazon-kindle-3rd-generation/dsc_5594/' title='DSC_5594'><img width="150" height="150" src="http://www.scienco.org/wp-content/DSC_5594-150x150.jpg" class="attachment-thumbnail" alt="DSC_5594" title="DSC_5594" /></a>
<a href='http://www.scienco.org/2010/ugly-custom-case-for-amazon-kindle-3rd-generation/dsc_5593/' title='DSC_5593'><img width="150" height="150" src="http://www.scienco.org/wp-content/DSC_5593-150x150.jpg" class="attachment-thumbnail" alt="DSC_5593" title="DSC_5593" /></a>
</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scienco.org/2010/ugly-custom-case-for-amazon-kindle-3rd-generation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Simulation and Quantiles for the Scaled Inverse Chi-Square Distribution</title>
		<link>http://www.scienco.org/2008/simulation-and-quantiles-for-the-scaled-inverse-chi-square-distribution/</link>
		<comments>http://www.scienco.org/2008/simulation-and-quantiles-for-the-scaled-inverse-chi-square-distribution/#comments</comments>
		<pubDate>Mon, 27 Oct 2008 19:20:27 +0000</pubDate>
		<dc:creator>Mikkel Meyer Andersen</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Math]]></category>
		<category><![CDATA[R]]></category>
		<category><![CDATA[Statistics]]></category>

		<guid isPermaLink="false">http://www.scienco.org/?p=207</guid>
		<description><![CDATA[Although R supports a lot of different probability distributions, it does not support the scaled inverse chi-square distribution - well, not directly. But it can of course be implemented. Let . Because of how the scaled inverse chi-square distribution is defined, it's possible to simulate from it in R as follows (checking the arguments is [...]]]></description>
			<content:encoded><![CDATA[<p>Although R supports a lot of different probability distributions, it does not support the scaled inverse chi-square distribution - well, not directly. But it can of course be implemented.<span id="more-207"></span></p>
<p>Let <span class='MathJax_Preview'><img src='http://www.scienco.org/wp-content/plugins/latex/cache/tex_fec9a43f9b77606c9ef588ede1aebde6.gif' style=' padding-bottom:2px;' class='tex' alt="X \sim S \chi_\nu^{-2}" /></span>. Because of how the scaled inverse chi-square distribution is defined, it's possible to simulate from it in R as follows (checking the arguments is not included in the following code):</p>
<pre>
rinvchisq <- function(n, df, scale)
{
  return(scale * (1 / rchisq(n, df)))
}
</pre>
<p>When we're able to simulate from the distribution, we're able to find quantiles. But we can actually find those directly by using the definition of quantiles and the chi-squared distribution. Assume that we want to find the $\alpha$-quantile $x_\alpha$. Notice that with informal notation, the following holds:<br />
<p style='text-align:center;'><span class='MathJax_Preview'><img src='http://www.scienco.org/wp-content/plugins/latex/cache/tex_d0b1ad82bddb3ea64fbd2a6473a50284.gif' style='' class='tex' alt="<br />
\alpha =<br />
P\left (X \leq x_\alpha\right ) =<br />
P\left (S \chi_\nu^{-2} \leq x_\alpha\right ) =<br />
P\left (\chi_\nu^2 \geq \frac{S}{x_\alpha}\right ) =<br />
1 - P\left (\chi_\nu^2 \leq \frac{S}{x_\alpha}\right ) ,<br />
" /></span></p><br />
and hence<br />
<p style='text-align:center;'><span class='MathJax_Preview'><img src='http://www.scienco.org/wp-content/plugins/latex/cache/tex_ceb9ae29e1cb2ae84cb17c3fb81ac287.gif' style='' class='tex' alt="P\left (\chi_\nu^2 \leq \frac{S}{x_\alpha}\right ) = 1 - \alpha." /></span></p></p>
<p>If <span class='MathJax_Preview'><img src='http://www.scienco.org/wp-content/plugins/latex/cache/tex_38269120e225e8b3905398158bc60b43.gif' style=' padding-bottom:2px;' class='tex' alt="Y \sim \chi_\nu^2" /></span>, then <span class='MathJax_Preview'><img src='http://www.scienco.org/wp-content/plugins/latex/cache/tex_098d83cdddcc2fb53089b5a0e882d5d2.gif' style=' padding-bottom:2px;' class='tex' alt="\frac{S}{x_\alpha}" /></span> is the <span class='MathJax_Preview'><img src='http://www.scienco.org/wp-content/plugins/latex/cache/tex_378df00d12056b404d7d02aef9d8650b.gif' style=' padding-bottom:2px;' class='tex' alt="1-\alpha" /></span>-quantile <span class='MathJax_Preview'><img src='http://www.scienco.org/wp-content/plugins/latex/cache/tex_3ac1fc536899bee8d658a8dec3dd380a.gif' style=' padding-bottom:2px;' class='tex' alt="y_{1-\alpha}" /></span> for <span class='MathJax_Preview'><img src='http://www.scienco.org/wp-content/plugins/latex/cache/tex_57cec4137b614c87cb4e24a3d003a3e0.gif' style=' padding-bottom:2px;' class='tex' alt="Y" /></span>. All together we now have:<br />
<p style='text-align:center;'><span class='MathJax_Preview'><img src='http://www.scienco.org/wp-content/plugins/latex/cache/tex_77d143a1a24990164df885cbe0250db5.gif' style='' class='tex' alt="x_\alpha = \frac{S}{y_{1-\alpha}}." /></span></p></p>
<p>Because of this, we can implement the following in R (checking the arguments is still not included in the following code):</p>
<pre>
qinvchisq <- function(p, df, scale)
{
  return(scale / qchisq(1 - p, df))
}
</pre>
<p>Checking the functions can be done like this:</p>
<pre>
invchisqcheck <- function(p, n, df, scale)
{
  cat("Check of rinvchisq and qinvchisq...\n")
  cat("Quantiles:", p, "\n")
  cat("Simulated with rinvchisq:\n")
  cat(quantile(rinvchisq(simulations, df, scale), quantiles), "\n")
  cat("Calculated with qinvchisq:\n")
  cat(qinvchisq(quantiles, df, scale), "\n")
}

invchisqcheck(c(0.025, 0.975), 100000, 10, 1)
invchisqcheck(c(0.025, 0.975), 100000, 11, 68)
</pre>
<p>For further information, please refer to <a href="http://en.wikipedia.org/wiki/Scale-inverse-chi-square_distribution">http://en.wikipedia.org/wiki/Scale-inverse-chi-square_distribution</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scienco.org/2008/simulation-and-quantiles-for-the-scaled-inverse-chi-square-distribution/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

