My question is similar to this link   I am trying to build a random forest for a binary response (1 &amp; 0). Let's say we have 10,000 different records and I am building 500 trees. Is there a way to score the records in terms of the certainty / confidence / likelihood of being categorized in category 1 (for example)? The link above suggests using the number of votes among all 500 trees, but this way can only give me up to 500 different scores, how can I differentiate further for these 10,000 records? (Like regression, the scores can be easily obtained).   One solution is to average the score of each tree in the forest. the tree is the probability of 1s in the final node. Anyone know how to produce that average in R? I couldnt find this in the randomForest package. I think if I write my own codes to do that it , the run time may not be as fast as a built-in function.
If I run a randomForest model, I can then make predictions based on the model.  Is there a way to get a prediction interval of each of the predictions such that I know how "sure" the model is of its answer.  If this is possible is it simply based on the variability of the dependent variable for the whole model or will it have wider and narrower intervals depending on the particular decision tree that was followed for a particular prediction?
What type of lens will auto-focus on Nikon bodies without a focus motor? What can I do when getting “This question body does not meet our quality standards”? While trying to ask a question, I got the error message     This question body does not meet our quality standards. Please make sure that it completely describes your problem - including what you have already tried - and is written using proper grammar.    Why am I getting this message? What can I do to get the system to accept my question? Can you be more specific? What are good resources on how to ask high-quality questions?      For more information, see  in the . I'm trying to parse an INI file using C++. Any tips on what is the best way to achieve this? Should I use the Windows API tools for INI file processing (with which I am totally unfamiliar), an open-source solution or attempt to parse it manually? Formation of ammonia from air and moisture On extended bicycle trips I sometimes slept under a plastic sheet, which helped with mosquitoes on hot nights. But there was a noticeable build-up of ammonia which made this almost impossible for more than an hour or so at a time.   Air is mostly nitrogen $(N_2)$ and there is always water (containing hydrogen) on a humid day. But I wonder about the mechanism for the formation of ammonia under these circumstances? There are (according to Wiki) trace amounts of methane and $H_2$ in the air. But methane and hydrogen (g) are I think pretty stable.   I wonder if the presence of exhaled air (containing $CO_2)$ could be a factor?  Thanks for any ideas. Does there exist a set L of pairwise disjoint lines, each line in an axis direction, in $\mathbb{R}^3$ such that their union is equal equal to $\{ x : x \text{ has at least one irrational coordinate}\}$? I'm searching how to remove the chapter+section number on the theorem numbering with a section counter.  With no section counter it's like:  \newtheorem{thm}{Title} Chapter1 ----Section 1 --------thm 1 --------thm 2 ----Section 2 --------thm 3 --------thm 4 Chapter2 ----Section 1 --------thm 5 --------thm 6 ----Section 2 --------thm 7 --------thm 8   And with the section counter:  \newtheorem{thm}{Title}[section] Chapter 1 ----Section 1 --------thm 1.1.1 --------thm 1.1.2 ----Section 2 --------thm 1.2.1 --------thm 1.2.2 Chapter 2 ----Section 1 --------thm 2.1.1 --------thm 2.1.2 ----Section 2 --------thm 2.2.1 --------thm 2.2.2   And I want numbering my theorems like this:  \newtheorem???????? Chapter 1 ----Section 1 --------thm 1 --------thm 2 ----Section 2 --------thm 1 --------thm 2 Chapter 2 ----Section 1 --------thm 1 --------thm 2 ----Section 2 --------thm 1 --------thm 2   I know it's always a pain to remove such things, thanks for whoever will help me ^^ How to integrate $\int_0^{\pi/2}\frac{\sin^nx}{\sin^nx+\cos^nx}dx$? Possible Duplicate:          How can we integrate $$\int_0^\frac{\pi}2\frac{\sin^nx}{\sin^nx+\cos^nx}\,\mathrm dx , \,\,\,\,\,\,\,\,\, n\in N \quad?$$ Thanks for any hint. There is an UI issue for the ranking div when a user crossed 200 reputation When a user just crossed 200, or 200+ reputation, the ranked div (i.e., top 10% overall) is trying to display. But rank calculation can be done on end of the UTC day. So instead of the ranking div, there is a blue colored hyphen is visible to users, it may be the initial loader for the ranking div.  I saw this UI issue previously too for the same scenario. Can this be fixed? Polynomial divisibility is unchanged by coeff. field extension I would like to verify the validity of the following line of thought:  Let $K \subset E$ be a field extension. Let $K[x]$ be the polynomial ring over $x$ and denote $K(x)$ its field of quotients (the rational functions over $K$).  Now assume $f(x)=g(x)h(x)$ with $f(x),g(x) \in K[x]$ and $h(x) \in E[x]$ and all $f$, $g$, $h$ are different than zero. Then $\frac{f(x)}{g(x)} = h(x)$ in $E(x)$. So $h(x) \in K(x)$. But $h(x)$ is a polynomial, so $h(x) \in K[x]$.  Is there any other simpler argument than that?  Added:  Let me be more specific. Let $x^p - a \in K[x]$, with $p$ being prime and $char(K)=p$. Let $b$ be the unique root of $x^p - a$ in its splitting field $K(b)$. Then $x^p - a=(x-b)^p \in K(b)[x].$ Let $m_b(x) \in K[x]$ be the minimal polynomial of $b$ over $K$. Then $m_b(x)$ divides $(x-b)^p$ and so $m_b(x)=(x-b)^l$ and $l$ is the smallest positive integer for which $(x-b)^l \in K[x]$. Let $p = lq+r$ where $0 \ge &lt;l$. Then $x^p-a=(m_b(x))^q (x-b)^r$. Can i conclude that $(x-b)^r \in K[x]$ and so $r=0$ by the minimality of $l$?  Thanks. Android app intermittently shows blank body in questions and answers (multiple sites) Note: the bug has returned in version 1.0.89 in a somewhat different form. See:      This possible bug report is similar to the bug in  that was deemed not-reproducible.  I can reproduce something similar with more recent app &amp; Android versions.   App Version: 1.0.34 (original report; is still present in 1.0.38, 1.0.42, 1.0.58) Android Version: 4.4 (up to 4.4.4) Device: Motorola Droid Maxx   In the examples below, you can see some blank answer bodies.  These are on different sites, and represent answers with both edited and non-edited text. In the first example, I clicked on the top answer tab to get to the answers, and in the second example I clicked on the bottom "View n Answers" button. (Trying to be a good little tester!)  Because I've seen this blank-answer-body intermittently over the past couple weeks (before the May 7 update), my process to test was just to go to the first site I frequent and then systematically click through the question list until I found a question with answers in which at least one answer was blank.  For all three sites shown below, it was within the first 5 or 7 questions sorted by newest.  Please note that I have seen many questions with several answers, none of which were blank. It is truly intermittent.  Example blank answer body at Workplace.SE:    Example blank answer body at Programmers.SE:    Example blank answer body at UX.SE:    And now here's the kicker, which makes me think this is some sort of content-loading latency issue rather than a rendering issue:  I returned to the left-side menu, selected the User Experience site, picked the same question as above, and then clicked the top answer tab to view answers again, and lo and behold the text is there:    I then went back to the other questions with blank answers, shown above, and the answer bodies were no longer blank.  I am happy to go through more tests/paths and do screenshots if it is helpful.  The same bug also appears in question bodies. When administering Linux systems I often find myself struggling to track down the culprit after a partition goes full. I normally use du / | sort -nr but on a large filesystem this takes a long time before any results are returned.  Also, this is usually successful in highlighting the worst offender but I've often found myself resorting to du without the sort in more subtle cases and then had to trawl through the output.  I'd prefer a command line solution which relies on standard Linux commands since I have to administer quite a few systems and installing new software is a hassle (especially when out of disk space!) How do I enable hibernation on Wubi? I installed Ubuntu on my Windows 7 Sager laptop using Wubi. Hibernate (i.e. suspend to disc) is not an option from the power icon, only suspend, shutdown, etc. Hibernate is also not an option from my battery/lid close options. I understand that hibernation is disabled by default in Ubuntu 12.04. I tried running pm-hibernate but I get the following message:  Looking for splash system... none  s2disk: Snapshotting system   and then the computer just hangs with a black screen. According to the documentation  if this fails then I can't enable hibernate but it offers no help in making pm-hibernate succeed.  Could swap be my problem? It looks like I have very small swap:  user@ubuntu:~$ cat /proc/swaps Filename                Type        Size    Used    Priority /host/ubuntu/disks/swap.disk            file        262140  0   -1   The advice on  is only for the author's set up (e.g. I don't have an Ubuntu install disk since I used Wubi) and he says that 'INFO: This will not work for 12.04, resume from hibernate work differently in 12.04.'  Any advice? I really need to get hibernate working to use my laptop as a, er, laptop.  Thanks Delete all but the most recent n file for each group of files that share the same prefix in a directory My question is a bit different from some older questions simply asking for "deleting all but the most recent n files in a directory".  I have a directory that contains different 'groups' of files where each group of files share some arbitrary prefix and each group has at least one file. I do not know these prefixes in advance and I do not know how many groups there are.  EDIT: actually, I know something about the file names, that is they all follow the pattern prefix-some_digits-some_digits.tar.bz2. The only thing matters here is the prefix part, and we can assume that within each prefix there is no digit or dash.  I want to do the following in a bash script:   Go through the given directory, identify all existing 'groups', and for each group of files, delete all but the most recent n files of the group only. If there are less than n files for a group, do nothing for that group, i.e. do not delete any file for that group.   What is a robust and safe way of doing the above in bash? Could you please explain the commands step-by-step? This question is a possibly harder version of: .  Question.  Let $f,g :\mathbb R\to\mathbb R$, such that \begin{align} f(x-y)=f(x)\, g(y)-f(y)\, g(x), \tag{1}\\ g(x-y)=g(x)\, g(y)+f(x)\, f(y), \tag{2} \end{align} for all $x,y \in \mathbb{R} $. If $g$ is continuous at $x=0$ and not identically zero, then there exists an $\alpha\in\mathbb R$, such  $$ f(x)=\sin \alpha x\quad\text{and}\quad g(x)=\cos \alpha x. $$ Is there a pair of discontinuous $f$ and $g$ satisfying $(1)$ and $(2)$?  Update. If $\ell :\mathbb R\to\mathbb R$ is a linear functional over $\mathbb Q$ (i.e., $\ell(qx+ry)=q\ell(x)+r\ell(y)$, for all $x,y\in\mathbb R$ and $q,r\in\mathbb Q$), then $$ \sin\big(\ell(x)\big), \quad \cos\big(\ell(x)\big), $$ satisfy $(1)$ and $(2)$. Discontinuous such functionals do exist, and they are obtainable using Zorn's Lemma (equivalently the Axiom of Choice.) This takes care of the second question. save as a video as .mp4 Does the war have an ending in Planetside 2? As enemy bases are captured, they just seem to respawn right in the middle of friendly captured territory. This is looking like a perpetual cycle, and none of the three teams ever gets closer than to the very edge of winning the whole continent, only to lose lots of territory again.  So is this by design? Is Planetside 2 eternally to be at war, with no winner ever? I was hoping it would be more like a 'match'. I admit that both are almost the same thing, but there is at least the closure of winning/losing sides this way. What does my internet provider know about my online activities? What does my internet service provider know about my online activites in these cases?   plain server (www, ftp, whatever) connection and provider's DNS secured (e.g. TLS) server connection and provider's DNS plain server (www, ftp, whatever) connection and an non-provider non-logging DNS secured (e.g. TLS) server (www, ftp, whatever) connection and non-provider non-logging DNS   In case 4) does my provider know anything more about my online behaviour than "IP w.x.y.z was assigned to Foo Bar between connect-time and disconnect-time" (i.e. only the duration my router was connected)?  What traffic does need to go through the provider's infrastructure to make my connection work at all? Message appearing when a user was removed.     It seems I lost 1765 reputation points on Stack Overflow yesterday. The reason given in my history is "removed", with the description of "User was removed ()". I don't understand what that means. What caused this? I am new to Salesforce and hence a lot of silly questions. What is the rational behind defining future methods as Static? I mean has these methods been not static what harm would have they caused? I want to draw a perfect rectangle. How can I do that with QGIS v.3+?  .  Is there a similar solution for the latest QGIS version?