How to enter series of points along certain angle at regular distances in ArcMap?

Question: I would like to enter a series of points along a certain angle in ArcMap.  I have a UTM coordinate as a starting point, and from that I'd like to enter 10 points at a 120 degree bearing every 50 meters. What is the best way to do this?
Answer: From the context menu while digitizing a new line I would use Absolute X,Y to enter the coordinates of the start vertex and Direction/Length to do the second (and last) vertex 120 degrees and 500 metres away.
You then have a selected line which is ready for Construct Points which "creates new point features at intervals along a selected line".
Answer: perhaps draw the line using the create features tool. right click for angle/bearing (can't remember) and put 120 degrees. Then right click and hit length, enter 50 meters. This will lock your draw feature tool into a 50 meter line at 120 degrees. continue this 10 more times then use Data Management > Features > Feature Vertices to Points.
There is probably a better way but this should work
Answer: This seems like a simple trigonometry task, perhaps excel is the easiest approach. You should be able to set up a simple recursive spreadsheet using the equations below.
Assuming your 0 degree line coincides with the positive direction on the y axis then:
x1 = x + 25
y1 = y + 25*sqrt(3)
Where (x,y) is the coordinates of your starting point and (x1,y1) give you the first point. Now just repeat 49 more times :)
Answer: You can use the Direction-Distance tool from the Editor toolbar:

The tool creates a point using a distance from a known point plus a direction from a known point to define a bearing line.
A step by step instruction can be found in ArcGIS help.


Switching from indices to names (or other attributes) in lists in R for large datasets. (iGraph)

Question: I am working with a graph object (igraph package) in R.  I apply a function called" get.shortest.paths()" that provides the shortest paths from a given vertex to all the other vertices in the graph.
The algorithm returns a list, where each element of the list corresponds to a target vertex, and contains the vertex indices of all the vertices on the shortest path between the source and the target.
For example;
head(get.shortest.paths(graph, from = V(graph)[1], to = V(graph), mode = "out"))
[[1]]
[1] 0 (source and target are the same)
[[2]]
[1]     0 91835 38405 89704     1
[[3]]
[1]     0 91835 12104 39002 22670     2
[[4]]
[1]     0 62386 36754 89246 31045     3

The problem is when I want to go from vertex indices to vertex names.  Something like this;
[[1]]
[1] "gene 1"
[[2]]
[1]     "gene 1"  "protein 45" "protein 83" "protein 70"     "gene 2"
[[3]]
[1]     "gene 1" "protein 45" "protein 30"  "reaction 2" "protein 404"     "gene 3"
[[4]]
[1]     "gene 1" "protein 4" "reaction 12" "protein 19"  "protein 494"   "gene 4"

I try to do this by using lapply()
path.index.list <-  get.shortest.paths(graph, from = V(graph)[1], to = V(cn), mode = "out")
path.name.list <- lapply(path.index.list, FUN = function(path) V(graph)[path]$name)

... but this takes a very long time.  "For" loops take just as long.  In fact, the exact time I needed to covert from indices to names for just one source vertex to all other 100,000+ vertices was...
system.time(lapply(path.index.list, FUN = function(path) V(graph)[path]$name))
  user  system elapsed
608.62  152.69  761.66

... which comes to about 900 days for the whole graph.
Is this one of those a "pass-by-reference" vs "pass-by-value" problems and if so can someone help me understand how to solve it?  I have heard of using hashes or environment functions in R to solve things like this, can anyone comment on that?   I have also heard of some packages in R that can help address this?
Basically, how can I solve this without having to code in C?
Answer: Query the names of the vertices in advance and index that in lapply:
names <- V(graph)$name
lapply(path.index.list, FUN = function(path) names[path])

I guess this is going to be much faster because lapply won't have to build V(graph) and the name list every time just to select a sublist of it.
Answer: Yes, I originally used the lapply method described by use "Tamás".  I am getting about 230 seconds per iteration (about 2 seconds per 1000 items).  I tried using the "fastmatch" package combined with memory allocation using matrices and speed actually went down.  I took this to mean this was more an issue with how fast R looks up items then memory.  I need to get this down to less than 6 seconds per iteration for this actually to be practical.  I guess I'm going to C...


quantum teleportation

Question: I don't know much about quantum teleportation but I read that scientists have succeeded in various quantum teleportation experiments. I'm wondering if one researcher were just inside the event horizon of a black hole, and another just outside, could the one outside teleport anything to the one inside? I'm assuming he'd never be able to know if he succeeded or not, and that the one inside could not teleport anything out.
Comment: Attention: Scientists haven't succeeded in teleportation (I'd better write an answer, though). So you are actually asking two different questions...
Comment: http://www.sciencemag.org/news/2015/12/physicists-figure-out-how-retrieve-information-black-hole
Answer: The answer is no, because quantum teleportation requires normal communication to work. The process is that we assume one experimenter has two qubits (small quantum systems), A and B, while another has a third, C. We assume B and C are initially in an entangled state. To perform teleportation, you measure A and B together, and then you call your friend and tell them what result you got. This then allows them to perform a procedure on C that recovers whatever information you had stored in A.
This works/is useful because it allows you to send A without measuring it and disturbing the information, but it does not allow you to send information unless you can also contact your friend classically to tell them what your measurement result was. So if one of you is inside a black hole, you can't perform the teleportation protocol.
Comment: Even if it didn't use normal communication, still exists the problem of the horizon. Since the qubits are respectively inside and outside of the horizon, it is not sure that the entanglement holds. In 2015 an analogue with dumb holes was performed and looks like the entanglement could survive but in presence of firewalls for example, is not that easy (c.f. https://journals.aps.org/pra/abstract/10.1103/PhysRevA.81.032320 and https://journals.aps.org/prl/abstract/10.1103/PhysRevLett.115.031301).
Comment: @AlejandroMenaya I think this is worthy to promote to an answer, because the main part in the question was about crossing the horizon, and it's not dealt with yet.
Answer: A clarification about the premises of this question: So far, scientists haven't succeeded in any teleportation experiments (and so far there is no hint that in principle teleportation is possible):
Up to day, what are sometimes called "teleportation experiments" involve the observation of entangled pairs of particles. Here we talk about "teleportation" of information, not of matter, but even this doesn't happen.
Such experiments measure a particle's attribute, e.g. spin, and infer the spin of the other particle of the pair, which is found at a large distance; the crucial point is that neither of the spins was determined before the measurement. So, by acting on the nearby particle, the far-away particle acquired its spin value. However, the experimenter neither chose nor modified the nearby spin. So, he didn't pass any information to the far-away particle. It's still a tremendous find in terms of quantum mechanics but certainly not teleportation...
Giving a short answer though to your hypothetical question, it will probably depend on what the means of teleportation will be ... and at which point inside a black hole information gets lost :\
Comment: This is not true. Consider this experiment (from 2009), where teleportation is accomplished after preparing the teleported qubit in a known state, which is then recovered afterwards https://arxiv.org/abs/0907.5240
Comment: Or this one, in which the qubits were photon qubits distributed over a fiber network in Calgary https://arxiv.org/abs/1605.08814
Comment: Okay, I had in mind Bell / Aspect type experiments. I'll read your links.
Comment: After reading the links:

0907.5240 is about quantum cryptography. Teleportation here refers to transfering information securely, by issuing a key that enables the receiver to read his copy of the "message". It involves that "the  result  of  the  measurement  on  ion A is relayed through a classical communication channel", i.e. the receiving end must learn the result of a measurement at the sending end. Of course this means that for teleportation of information and matter there are no advantages over e.g. internet or remote 3-d printing (however there are notable ones for cryptography).
Comment: @zeldredge About 1605.08814, I still try to wrap my brain around it, but I think it's of the same kind. And, this article popularizing the paper says the following: "The initial Bell measurement is made by Alice on the photon to be cloned and also on one photon in a pair of entangled photons. The result of this measurement is then sent to Bob, who also receives the other photon in the entangled pair. Using Alice's measurement information, Bob then makes a further measurement on the entangled photon, which puts it into the same quantum state as the cloned photon."
Comment: Ok, but this is what's always meant by "quantum teleportation" in the field of quantum info -- a measurement is made, and a classical signal sent, which allows the recovery of the original quantum state on the receiving end in a way that's agnostic to the underlying state. Beyond cryptography, it's also useful for moving qubits around within a computer.
Comment: @zeldredge Yes, but this is not what teleportation means when used in quantum mechanics (not quantum info) and in everyday language - which I understand the OP had in mind.
Answer: As stated in previous answers, and in the comments, quantum teleportation protocol let us to send the state of entangled qubits with the help of sub-luminal communication. In this video the essential concept is explained in a very friendly way. However the important part of the sub-luminal communication is not evplained in detail.
Schemattically we can perform the teleportation protocol as follows:

Taking the state $\phi_1$ we want to teleport and a couple of entangled systems $\psi_2$ and $\psi_3$, for short $\psi_{23}$.
Entangle the firs state with one of the system in $\psi_{12}$, obtaining a "very" entangled system $\psi_{123}$
Perform a series of transformations, which will lead to a superposition of the system $\psi_{12}$ and the third part $\psi_3$
By measuring and informing about the results in $\psi_{12}$ one can obtain the desired state copied in $\psi_3$.

Notice is important the fact that we have to inform about the state of $\psi_{12}$ in order to select correctly the state of $\psi_3$.
But there are technical problems: first of all, entanglement is a very fragile property, so the experiment must be taken carefully under controlled circumstances. Furthermore, this protoc ol works well (and was developed) in the context of quantum mechanichs, which treats time differently as Special/General Relativity.
Now let's move on to a black hole: near the event horizon, spacetime is perfectly regular (a free-falling observer cannot notice the difference between inside and outside the horizon), but the characteristic of the time coordinate changes. To make it simpler, let's think about Schwarschild BH, which is one of the simplest. In this spacetime, the time flow (the killing vector associated with time translations) goes form time-like to space-like once you cross the horizon, which means that once you entered a black hole, the only causal curve you can follow (the only trajectory permissible) goes trhough the singularity. Since thw communication used in the teleportation protocol is subluminal (and, therfor, causal), no information can escape of the black hole, so the teleportation protocol cannot hold here, as stated in the previous answers.
Allowing this caveat, it is possible that even the concept of information of a particle inside the black hole has no physical meaning. Since the qubits are respectively inside and outside of the horizon, it is not sure that the entanglement holds.  This is related, if not the central point, of loss information paradox. Nowadays is thought that the information of a particle falling into a black hole is not contained inside the black hole, but that leaves an imprint in the horizon (c.f Soft Hair on Black Holes by S. Hawking et all.)
In 2015 an analogue with dumb holes was performed and looks like the entanglement could survive but in presence of firewalls for example, is not that easy (c.f. journals.aps.org/pra/abstract/10.1103/PhysRevA.81.032320 and journals.aps.org/prl/abstract/10.1103/PhysRevLett.115.031301). So in conclusion: even if the teleportation protocol holds, if communication of states between inside and outside of black hole is possible, it is not sure that the basis of the transportation protocol (i.e. the quantum entanglement) can even exist.

quantum teleportation


Current along a Resistor with variable resistivity in DC circuit

Question: I had a question regarding the current along a resistor with variable resistivity. If you have a normal resistor with constant resistivity throughout its length, and you apply a constant DC voltage across it, the current at any point on the restitor is the same, the average quantity of charges travelling per second remains the same. However, if I have a resitor with some length $L$, and with variable resistivity across its length, and I apply a constant DC voltage across the ends of the resistor, will the current be constant, or will it change as a function of its position on the resistor? i.e lower towards the one end and higher towards the other? Or is the current constant throughout the resitor? If so why?
Comment: A better word than *varying* might be *differing* (or similar; maybe an English native can help out here). The term varying is often used for values that change over *time* but you are refering to changes over *distance*. So, you resistance is actually *constant* but just with different constant values at different points. That makes a crucial difference to the answer. Not sure if this is a big deal or if it is just me, but I misread initially.
Comment: Probably it would be useful to close down the question as there are good asnwers added.
Answer: The current will still be constant, otherwise there would be a violation of conservation of charge.
What will be different is the electric field in the resistor. For a uniform resistor the electric field is uniform in the resistor with a magnitude of
$$E=\frac{V}{d}$$
Where $V$ is the voltage drop across the entire resistor and $d$ is the length of the resistor.
If the resistance is not uniform along its length, then the voltage drop per unit length of the resistor will not be constant, even though the total voltage drop is the same. Therefore the electric field will not be uniform  along the length of the resistor.
Hope this helps.
Comment: I accidently downvoted this answer. Could you please modify it a bit so that I can delete my downvote? Thanks in advance :)
Comment: @zltn.guba I just did. Was wondering why it was downvoted. Thanks for letting me know
Answer: Whatever goes into a branch of a DC resisitive circuit MUST come out. The current cannot 'stop' or 'slow' at different points.
You could break your resistor down to a series of infinitesssimal resistors of different values and see that the current must flow through them all.
The water flow analogy works here - there is no 'accumulator' in the circuit so the current is constant.
Comment: This is only true for time-independent case, as there the continuity equation suggests $\nabla \mathbf{j}=0$
, which is just the first law of Kirchhoff. But in general charge can accumulate in a non-uniform resistance which results in a non-uniform charge distribution.
Answer: If the incoming current is not equal to the outgoing current for an infinitesimal volume then charge gets accumulated at that infinitesimal volume. The relation between the charge density and the current density is given by the continuity equation
\begin{equation}
\partial_t \rho + \nabla \mathbf{j} = 0
\end{equation}
Now if the absolute value of the incoming current density is not the same as the absolute value of the outgoing current density then $\partial_t \rho$ is nonzero. This suggests that we are talking about a time-dependent process. In contrast to the previous answers, it might be possible to accumulate charge in a circuit, but in a static process the charge density cannot change, so
\begin{equation}
\nabla \mathbf{j} = 0
\end{equation}
for a static process, which is just a statement that the absolute value of the incoming current is the same as the absolute value of the outgoing current.
The reason why we are not dealing with processes where charge accumulation happens is that the time-scale for them is very short. Let's say that you have a setup in which you can have a nontrivial charge distribution. Shortly after you turn on the current generator, the charge distribution in the system is already static, which means you can use $\nabla \mathbf{j} =0 $. This statement is also known as the first law of Kirchhoff.
So in a nutshell, the continuity equation gives the connection between the current density and the charge density and in a static process you can use the first law of Kirchhoff, but in general time-dependent process this law does not hold.
To explicitly answer your questions: in the static limit the current will be the same along the resistor, while the voltage drop will vary along it. Also the electric field will depend on the position along the resistor, and a non-trivial charge distribution will be created.
Answer: I interpret the question as asking to a resistor of gradually different resistances across its geometry. In other words, the resistance is constant (over time) but differes from point to point along its length.
Will the current be the same at all points throughout your resistor?
Yes.
Here are two arguments for that conclusion:
The resistance perspective
A resistor in a circuit will slow down a charge that tries to move through. Intuitively we can imagine charges as "queueing up" behind one another, when the first charge is slowed down. Thus they all slow down behind it. When leaving the resistor, they will all keep moving with this new slower drift speed (and if slowed down further, then the ones behind will keep pushing to keep this drift speed constant). So, now this new, lower current is the new circuit-wide current.

Firstly, note that the current in the wire segments is the same as through the resistor. Those wire segments do corresponds to resistors with a very low (zero) resistance. So, we are dealing with a circuit where the current becomes constant even across different components.

Secondly, note that adding a another resistor will slow down the charges even more. They will thus "queue up" behind one another at this resistor as well, effectively slowing down the total circuit-wide current even more and this new slower current is again the same throughout and in both resistors.

So, the currect along any series connection of components in a circuit at steady state will be constant at all points. Your scenario with a resistor of gradually differing resistance along its length corresponds to a circuit with many resistors in series. Just imagine those resistances squeezed closely together and each being very, very thin, constituting just a slice each. The current must be the same throughout such component of the same logic.
This was the resistance-view on the question. There is also the, maybe simpler, current-view:
The current perspective
If, say, 10 charges enter a point each second, then also 10 charges must leave each second. Otherwise, where would they go or where would they come from?

If fewer leave than enter each second, then some must accumulate within that point. Such a point will thus gain a larger and larger repulsion against new incoming charge, slowing it down until just as many enter as leave each second.

If more leave than enter each second then... well, where would they come from? Charge cannot just appear out of thin air, so this is impossible.

In conclusion, for steady state we know that all current in must equal all current out at any point. This includes points within resistors. So, the current must be constant throughout your resistor.


Cursor has disappeared after upgrading to Windows 10?

Question: So, I've just updated from Windows 8 to Windows 10 and my cursor has disappeared.
It does show for 1 minute when rebooted, but then disappears. Very strange??  I have no idea how to fix it and I'm not a fan of touch screen.
Can anyone assist me (in simple language - I'm a bit of a techphobe)
Thanks
Answer: Here's a list of easy steps and all you need is the TAB and ARROW KEYS.

Hit your windows button so the pop up menu appears (use arrows to reach setting - you need to scroll down- press enter to select)
Type in mouse& TouchPad setting. Your computer will search for it
After selecting find "additional mouse options at the bottom of the screen (you may need to use the tab button to go down)
Select the last tab. This should be the built in mouse pad.
Select "enable device".(press tab and then enter to enable it).  This should highlight your mouse pad or "smart pad"

After applying the setting it should appear.
Comment: I have no idea why my touchpad suddenly got disabled but this fixed it - thanks!
Answer: Or in my case the Mouse Driver in Windows 10 was not compatible with the touchpad on the HP Ultrabook. Once I rolled back my driver the mouse reappeared.
To do this without a mouse you need to use the keyboard:
Windows Key-> type "Device Manager" without the quotes and hit enter.
Use the tab to highlight the list then the down arrow to scroll to Mice and other pointing devices. Use the right arrow to expand it, then the down arrow to select your device (Probably PS/2 Compatible Device). Hit Enter.
You should now have a screen titled "PS/2 Compatible Mouse Properties". Use the tab key to put a dotted square on the "General" tab at the top of the screen then the right arrow to put the square on the "Driver" tab.
Finally use the tab key to highlight "Roll Back Driver" and hit Enter.
Following this you will need to reboot and your mouse pointer should be restored.
Comment: Rolling back driver definitely helped!!
Answer: For me it was as easy as:

Windows Key | search "Cursor and Pointer"
The focus was already on "Change Pointer Size" | press right arrow key
Close the Settings page

As soon as I pressed the arrow key my cursor showed up again.
Comment: This worked for me on Win10 20H2 recently. One other idea is to connect another mouse, or use the laptop trackpad if already using a separate mouse - this made the mouse appear for the original pointing device with this issue.
Answer: You could try this:
https://www.youtube.com/watch?v=sA_oKgGynkI
The guide is for Windows 8, but should work in Windows 10.
You can use Win+X to quickly open your control panel.
You can also enable Mousekeys (LeftAlt+LeftShift+NumLock)
Comment: Please give full details in your answer. YouTube videos disappear all the time and your answer will be almost useless if that video goes. Linking to a video is fine to acknowledge your source and give more information, but it shouldn't be the only information.


Can we have threaded comments?

Question: The conversation often continues in the Comments and important information is held in the comments. I'd like to have threaded comments there.
Comment: If they were so packed with goodness, they should be rolled out into answers. Otherwise, they're noise.
Comment: @Steward: SO has already managed it by positioning itself as a Q&A site rather than a discussion site by discouraging random discussion in FAQ.
Comment: The problem with threaded comments is that the left margin will overflow in flame wars :)
Comment: And keep in mind everyone, the "comment section getting too big" complaint (which I don't buy) is solved by collapsable threading.  In fact, it need not even be collapsed once you can quickly discern where the sub "conversations" are.  This never ending lament from many of you guys that stuff should be moved to chat is silly.
Comment: Re: Mehrdad: I think flame wars happen in any comment stream, and the community policing needs to manage that whether there are threaded or single stream comments.

Re: random: I agree that comments sometimes contain great information that need to be refactored into the answer. My request for threaded comments is to make that process easier.
Comment: See my Greasemonkey script here: http://meta.stackexchange.com/questions/43055/greasemonkey-script-for-displaying-threaded-comments
Comment: @RobertHarvey I mean as a default.. REDDIT STYLE!! (Yes, I said the unspeakable).
Comment: @user1306322 see here: https://stackapps.com/questions/2050/threaded-comments?noredirect=1&lq=1
Comment: @random, `If they were so packed with goodness, they should be rolled out into answers. Otherwise, they're noise. – random Nov 26 '09 at 11:33`  Please explain why.  The charter of a conversation and the charter of an answer are distinct.  I find the current charter of an SE "comment" to be broken.
Comment: You certainly need discussion sin meta.stackoverflow because isn't this site all about discussion problems and enhancements to SO?
Comment: Hmm, I want to bring this into discussion again.  I still think threaded comments would be helpful.
Comment: @bobobobo we already have ways to get threaded comments.  There is chat, and a threaded comments script on Stackapps.
Comment: @balpha dead link, mind reposting your referenced script to stackapps and linking again?
Comment: @RobertHarvey can you link some of those userscripts from stackapps here? maybe as an answer so it won't get lost in comments
Answer: Jeff really hates threaded comments. Personally I like them - when represented in a useful way, with easy ways to mute/highlight appropriate subthreads, but I doubt that we'll ever see them on SO.
Having said that I like them, I'm not even sure they'd be appropriate for SO anyway, which is more designed for Q&A than discussion. Sometimes I wish there were some way of leaving the questions/answers as they are, but launching a new discussion (with threading) where suitable. Can't see it happening in the near future though.
Comment: Just open Wave!
Comment: I didn't know of Jeff's hatrid of threaded comments. have you noticed that when people merge information from comments into the answer the comments then read very strangely unless you have been following the conversation over time. There should be a way to mark a comment as integrated back into the answer.  Oops new feature request. I'm off to lunch
Comment: @bobobobo: You are late to the party, aren't you? ;)
Comment: Stew:  "Can we have threaded comments?"  Jeff: [I hate, I hate!!](http://www.youtube.com/watch?v=ifsMeule-C4#t=1m36s)
Comment: @LadybugKiller, I'm not.
Comment: @LadybugKiller http://support.google.com/wave/bin/answer.py?hl=en&answer=1083134
Answer: Threaded comments only appear to be more coherent at a superficial first glance.
What actually happens is that the discussion forks and that the same things are being discussed at different places or that you fail to notice important arguments because you are focused on a different thread. This is what I observe on Reddit, where coming to a consensus or forming an opinion on a matter is often impossible because everyone gets lost in the multithreaded, unchronological confusion.
The tangle of threads becomes even more incoherent when people don't reply in the appropriate thread but at the bottom of the discussion, as often happens on Facebook.
But the most inportant argument against threaded comments is that on this site all comments (should) focus on the question or answer they are attached to, and because of this unifying singe focus they should all remain part of a single discourse. Threaded comments would be like groups of people wandering off and discussing things among themselves instead of partaking in a shared decision process. Threaded comments would be like having each answer to a question on their own webpage so they no longer refer to each other.
tl;dr

In a comment to this answer, @bobobobo claims that "[t]hreading removes the need to make visual jumps upward across 10-15 posts to see what a new comment is in response to". That claim is utterly false.
Below is a screenshot of a threaded discussion on Reddit. The arrow connects the first comment to the opening post (at the arrow head) with the tenth direct reply to that comment (at the tail of the arrow). In a non-threaded, chronological view, a reader would indeed have to jump upward across nine other comments from the tenth reply to the comment it is a response to.
But in the threaded view, this need to jump is not reduced. On the contrary, it is increased, because in the meantime no less than 200 comments have been posted in reply to the first nine replies, making it necessary to jump upward across 200+ comments from the tenth reply to the comment is was a reply to.
This example shows that both in a chronological and a threaded view are there potentially equally many comments to jump. The major difference lies in the focus of the answering options. In threaded comments, there is an option to reply to each individual comment, which narrows the focus of the poster to that comment and reinforces the impulse to create ever sub-branching comment threads. In chronological comments, with a single textarea below the comment thread, the focus is on the opening post and the whole discussion.

reinforces
Comment: Can't you collapse the other threads?
Comment: @bobobobo Of course you can, but that doesn't reduce the demand character of the option to reply to every comment in between (which is the main argument of my answer). And collapsing everything between a comment and one of its replies doesn't make processing everything that you have now hidden any easier (which, I believe, was your argument).
Comment: +1 for the silly screenshot.
Comment: I feel like comparing randos on reddit and facebook to users who visit and post on meta is unfair. It's kind of the same as comparing users who have never visited meta to those who have spent enough time on meta. I get the knee-jerk reaction to change, but there are solutions to the problem visualized in your screenshot - even on reddit you can hit that `[−]` clicky text and collapse the thread, and there are also addons/userscripts which show you the floating preview of the posts from way way up the page to which the reply down below refers to, so you don't even have to scroll/click anything.
Comment: @bobobobo In psychology, the term *demand character* denotes qualities of a stimulus that make certain behaviors of a person more likely than others. For example, road markings visually guide drivers along their respective lanes, making it more likely that drivers steer along those lanes instead of into the oncoming traffic. This "visual guidance" is the demand characteristic of the road markings. The markings "demand" from the driver to drive along the lane, so to speak. Demand characteristics are important in advertising psychology and UI design (a road being a user interface).
Comment: Not threading the comments doesn't necessarily stop offtopic branching! You have to use modding to do that (which happens already) Threading removes the need to make visual jumps upward across 10-15 posts to see what a new comment is in response to
Comment: @bobobobo See my edit.
Comment: What is a "demand character"?
Comment: I also don't believe the argument that "most [meta] users wouldn't read other threads". I have a level of trust in an average meta user that they will.
Comment: if you have [Reddit Enhancement Suite](https://redditenhancementsuite.com/) installed you can hover cursor over `parent` comment action link and the relevant discussion preview should appear. I believe this should be possible to implement on SE via userscripts if need be.
Answer: Threaded comments and threaded answers would be great - for another site.
On this site, it would just encourage discussion, which is discouraged.
Comment: @bobobobo mind popping into [meta chat](https://chat.meta.stackexchange.com/rooms/89/tavern-on-the-meta) and discussing this in some more detail?
Answer: As Jon seems to address, threaded comments are great for following discussion. Jeff has said before that he explicitly wants to avoid discussion on SO, so if threaded comments help discussion, it would seem that adding threaded comments would, in a sense, be giving a blessing of sorts to discussions on SO.  It's nice in theory, but it goes against the current mission of the site.
I do like the idea of a discussion area, though. Often times, I have a question or discussion topic that I would very much like to bring in front of this particular community, but it's not necessarily programming related.  Sometimes you want to ask your "work peers" questions not necessarily related to your "work."
Answer: Threaded comments would be useful.
Compare these 2 views of the same discussion
unthreaded
(Visual jumping highlighted in red)

threaded
(Where the [-] indicates a collapsible region)

depth limit
It is reasonable to object to threaded comments because you don't want a tree that is too deep

If you limit it to one level deep, that would give some more flexibility while still keeping the conversation organized.
Answer: I wouldn't mind threaded comments that much, but I can make an argument against them:
It is too much of an investment in a distraction.
Discussions in comments shouldn't really happen: There's meta, and there's chat. The good comments directly relate to the question, not to other comments. So it's reasonable not to motivate even more use of comments for discussions than we already have, by making it more convenient.
(To be fair, one could argue meta sites are somewhat different than regular ones and the rule doesn't apply to them - but we're not talking about a meta-site-only feature, right?)
Comment: `but we're not talking about a meta-site-only feature, right?` - this wasn't clear to me from this question asked 10 years ago, so I'm not sure I made the right move by bountying it and not asking a new, more specific question. Personally, I think threaded comments for the Meta.SE make the most sense, a bit less for other metas, and not as much for main sites. Something tells me on main sites it would result in a major headache, but on metas it'd be fine.
Answer: I truly wonder why discussion is so discouraged herein. Some answers can be very difficult to get at and discussion about the answer could help a really good answer to emerge instead of having an endless list of partial answers or a hard to follow comment stream that needs to be completely followed through to get at the real juice.
On the other hand, I realize that many questions in the Stack Exchange sites are simple enough and warrant that a single right answer can do it.
A certain form of argumentative questions can be supported through the wiki mode. Perhaps having threaded comments only in the community wiki mode would be of great help in getting these hard questions to emerge. Since there are no reputation points involved in community wiki mode, editing them also solves the difficult task of assigning proper reputation points though there are some solutions to this.
It is true that arguments can be difficult to manage and often degenerate. That said, the community participating in the Stack Exchange sites is thus far very disciplined in this regards and seldom stray off topic. Yes, sure you can find plenty of examples where things just went wrong, but overall it is the exception.
Stack Exchange sites have gone a long way since their inception and are quickly becoming THE reference in many subjects. But it still lacks a certain depth, discouraging discussion certainly helped with the discipline, but it also gave the community a glass ceiling, shackles of sorts, that prevents more difficult answers to emerge on some questions.
In short, encouraging argumentation and discussion at large would most likely not be a good idea. But allowing some question to generate discussion and providing a specific UI enhancements to support discussion would benefit the whole community. Perhaps Community Wiki is the way, but perhaps a new mode of providing answers would be required to support argumentation in a constructive way.
Comment: Because Q&A sites aren't about the discussion. The idea is that relevant content belongs in an answer, or on some occasions on meta; the comments are mostly  scaffolding for arriving at a good answer.

Can we have threaded comments?


Can you heat water with additives?

Question: I have been curious about this question for a while. If you want to warm up a large amount of water, is it feasible to do this by adding a substance that has an exothermic reaction with the water? What is the relevant chemistry one has to know to work out how much the water would be heated up by?
Comment: Well... Swim in it :)
Comment: This is an interesting question. What do you want to do with the hot water? If you want it to be potable (fit for drinking), that would limit some answers.
Comment: Theodore Gray, in his book ("Theo Gray's Mad Science", Black Dog & Leventhal Publishers, Inc, NY, ©2009, pp. 234-237) uses 500 pounds of CaO to heat 700 gallons of water in a hot tub, predicting that the temperature would rise from 60 to 100 °F. He cheated a bit: the CaO was incrementally added to water in an inner tub, heating the water (already hot at the start because the outside temperature was 10 °F) in the surrounding tub, where he and his 2 kids were. Details in the reference plus two nice photographs.
Answer: From the comments:

What do you want to do with the hot water? Swim in it. I was thinking
  of thousands of liters

That's an interesting idea, but unfortunately, I don't think adding chemicals to a pool in order to heat it is a good idea (especially yellowish chemicals). The water temperature would drop in a few hours, tops, and you'd have to be constantly adding more chemicals to it. At some point, you'd have a pool of chemicals instead of a pool of water. Not to mention that the chemicals would probably end up being more expensive than the electricity or the gas bill to heat up the pool to the same temperature the conventional way.
A nice way of heating up pools is using solar water heating systems, and coupling them with the conventional heating systems, if necessary.
So... Is it feasible? I'd say it isn't. But since you said this was more of a thought experiment... The only scenario I can imagine where the best solution to heat up a pool is to add chemicals to it is: You have a small pool, very little time to heat it up, you want to heat it up to sauna-like temperatures, and although you'll only use it for a couple of hours you are willing to spend a lot of money to do so. In this case, I'd add some water to the pool, and then add the following reagents to it, making the following reaction:
$$\ce{NaOH + HCl -> NaCl + H2O} \\ \Delta H = -56\,200\ \mathrm{\frac{J}{mol}}$$
You can do the math, but I assure you it heats up pretty quickly. We used to neutralize concentrated acid in ~10 L plastic buckets, and if we "accidentally" neutralized too much at a time the bucket would start to heat up to a point you couldn't even touch it.
NaCl is kitchen salt, so no issues with toxicity if you do the math correctly. Salt water also makes you float better, which I think is a nice quality in a pool. There would be salt on the bottom, but I think that's nice too, makes it feel like the sea.
Comment: (For comparison with the calcium chloride, this works out at ~830 J/g.)
Comment: @Aesin it is intriguing to wonder how much higher this number can go.
Answer: You're looking for materials that either react with water with a large reaction enthalpy $\Delta H_\mathrm{r}$, or have a large enthalpy of solution $\Delta H_\mathrm{sol}$ (which really amounts to the same thing but with a slightly different scope).
The problem with this as a general method, though, is that water has a really high heat capacity: take a look at this table of heat capacities, which gives it as approximately 4.2 joules per gram per kelvin.
A common method of producing self-heating coffee cans is to combine anhydrous calcium chloride with water in a closed vessel surrounding the can. According to a vendor of calcium chloride, 100 % anhydrous $\ce{CaCl2}$ has a solution enthalpy of 737 joules per gram when dissolved in water.
Assuming an approximate density of water of 1 gram per millilitre, that means to heat a litre of water by 10 K, you'd need about:
$$ m_{\ce{CaCl2}} = \frac{m_\text{water} c_p \Delta T}{\Delta H_\text{sol}} = \frac{1000\ \mathrm{g} \times 4.2\ \mathrm{J\ g^{-1} K^{-1}} \times 10\ \mathrm{K}}{737\ \mathrm{J\ g^{-1}}} = 57\ \mathrm{g}$$
So, that's feasible, but you may have a different idea of a large amount of water. And, let's not forget, you're still adding stuff to the water, so it may not be suitable for what you wanted it for anymore.
Other notable reactions that can heat water include reacting it with lithium metal (~220 J/g), or dissolving sulfuric acid (~90 J/g). You're looking for materials that don't hold together particularly strongly (e.g. if they're a crystal, they have a relatively weak lattice), because you have to break those bonds to dissolve/react it, and also bind to water very strongly, because that's what gives you the exothermicity. Because of that, ionic materials and materials that form at least doubly charged ions when reacting with water are likely to be better candidates.
Comment: Thank you! I wonder if 737 is as high as you can get. You are right that I was thinking of thousands of liters although I only need to heat it by a few degrees. In fact it's mostly a thought experiment but an interesting one I hope.
Comment: @marshall: Well, calcium chloride is available in large quantities -- while more rare than NaCl or MgCl, it is occasionally used for gritting roads in winter in some places, for example. Getting it anhydrous in large quantities will likely be trickier, though.
Answer: How about mixing calcium carbonate and sulfuric acid with the water? There will be a lot of heat released (and carbon dioxide, of course), and the resulting calcium sulfate will, for the most part, just precipitate out.

Can you heat water with additives?


Possibility of default of Corporates A, AA, AAA bonds

Question: Have one heard these A, AA, or AAA bond can default. If there is a possibility, what should I do? buy US treasure only?
Comment: The treasury can default as well.  The last time was the Liberty Bond default of 1934.  I believe the US treasury has defaulted, on average, every 70 years since independence.
Answer:
Have one heard these A, AA, or AAA bond can default.

Yes they do default. The other aspect is they can get downgraded over the period. So what you are holding as AA bond, can quickly become a BB; if you sell, you would potentially make loss.
At times its an isolated instance, at times it is compounded by some other factors. For example 2008 downturn, quite a few Mortgage backed securities lost money. Quite a few other bonds lost their ratings. Investopedia has a good article.
Enron is another classic example with bonds rated high and going bust overnight.

If there is a possibility, what should I do?

In today's world, there is nothing that is 100% safe. So the best strategy is to diversify into multiple unrelated class of instruments.
Comment: So an AA bond would not be default without be downgraded first? In that case, if I held the bond to maturity, I still get my full amount back no matter it is rated how junk like B, BB-?
Comment: @Tony It depends; at times things go bad so fast that it may [or may not] be downgraded few hours before the bond goes bankrupt. Or an AAA bond over period of few months is classified as junk. One may already loose money as when it purchased it was AA, then when he trying to sell it becomes B or junk. A bond that is rated AA can go bust overnight and one can loose money. The charges are less likely. Note there is nothing explicitly guaranteed that AA bond will always give returns. A B, BB- bond may give returns when held to maturity. The chances of going bust are moderate [but higher than AA].


What is this noise I see when I close my eyes?

Question: I wonder what is this color noise I see when I close my eyes. The visual field is black but there is definitely some subtle color noise which I can "see." I wonder where it comes from.
Comment: Welcome to Health SE. In its current state, this question is very unclear. Could you give us some more details. What screen are you referring to? What do you mean you "see" a subtle noise? I'm afraid I'll have to close this unless you edit. Thanks :)
Comment: On Biology.SE: [What do you see when your eyes are closed?](http://biology.stackexchange.com/q/21523/9268)
Comment: @TFD I was using a metaphor ofc.
Comment: I suspected you weren't talking about antique French dressing room screens :-)
Comment: @michaelpri It's 2015, when someone says the "Screen is black", they are probably referring to computer screen in front of them, or using it as a metaphor for the current "vision" of their eyes. They probably wont be talking about an antique French dressing room screen, as those were not often black. Other then that the question is quite straightforward
Answer: You are seeing phosphenes.
These have been described in medical notes for thousands of years
They are assumed to be caused by random firing of optic nerves due to stray electrical stimulation in the brain, or pressure on the eye
Other causes are; sudden changes in air pressure, moving from bright light outside into a dark room, violent body motions (like coughing or sneezing), over stimulation (sexual, drugs, grief), diabetic shock, violent sports (boxing, rugby etc); all these may cause pressure on the eye, or over stimulation of the bodies electrical system
If you are getting increased phosphenes, bright flashes of light, or fixed objects appearing with your eyes closed, these may be a sign of eye nerve damage, and a trip to the doctor may be a good idea
Interestingly, this is similar to the CCD device in a camera chip. They are very susceptible to stray electrical charge, and this causes a low level background noise in the picture, even in a totally dark room

Cellular mechanisms underlying the pharmacological induction of phosphenes
Phosphenes
Wikipedia - Phosphene
Comment: I just want to emphasize the importance of going to the doctor if you see bright flashes of light or other unusual visual disturbances. Although often benign, they can be indicative of a variety of serious conditions, which are best treated when caught early.
Comment: @Sue This is only if dramatically changes in your lifetime. Most people see phosphenes as it is a normal sign of a working brain
Comment: I think it's super cool and interesting that our eyes and CCDs exhibit the same phenomena for similar reasons.


Quran has all answers

Question: If Allah has said the Quran is complete and detailed and easy to understand, what's the need for this site ?
Further, you say my question doesn't meet your 'quality standards' ?
Comment: see also: http://meta.stackexchange.com/questions/92074/what-can-i-do-when-getting-it-does-not-meet-our-quality-standards
Answer: Yes, Qur'an is a guide to a person and has all the answers or guides you to find right answers - be it religion or worldly life.
To answer your question, this is what the Qur'an has taught us:

"فاسأوا أهل الذكر إن كنتم لا تعلمون"….ask the people of knowledge if
  you do not know. (Qur'an 21:7, Qur'an 16:43)

Shaikh ibn ul-Uthaymeen رحمه الله stated, "In this noble ayat is instruction on the manner of seeking knowledge of an affair that is unknown to you, and that is that you ask the one upon knowledge in that affair".
Hence, the purpose of this site is to bring together the person who has knowledge regarding a certain subject from Qur'an and Sunnah and the person who is looking for answers, so that the person can learn from him.
Answer: Quran has all answers, but all people cannot understand all the information of Quran. Many information of Quran are in the form of puzzle and secret and not easy to understand.

[3:7]  It is He who has sent down to you, [O Muhammad], the Book; in
  it are verses [that are] precise - they are the foundation of the Book
  - and others unspecific. As for those in whose hearts is deviation [from truth], they will follow that of it which is unspecific, seeking
  discord and seeking an interpretation [suitable to them]. And no one
  knows its [true] interpretation except Allah. But those firm in
  knowledge say, "We believe in it. All [of it] is from our Lord." And
  no one will be reminded except those of understanding.
Answer:
You should only ask practical, answerable questions based on actual
  problems that you face. Chatty, open-ended questions diminish the
  usefulness of our site and push other questions off the front page.
Your questions should be reasonably scoped. If you can imagine an
  entire book that answers your question, you're asking too much.
If your motivation for asking the question is "I would like to
  participate in a discussion about ______", then you should not be
  asking here. However, if your motivation is "I would like others to
  explain ______ to me", then you are probably OK. (Discussions are of
  course welcome in our real time web chat.)

Read more here
Read this also: How to ask questions
Do not forget to read the whole FAQ.
Answer: Quran is indeed very easy to understand but our lives are not. When people ask questions on this site they ask about how to apply this EASY QURAN to this complicated life of ours.
Not asking open ended question wrt to Islam is kind of not doing justice to Muslims who seek full knowledge about Islam.
There are many occasions (and this is one of them) where I disagree with the policies of stackexchange. But I respect & hold those policies as a user of stackexchange.
Answer: Please think why God has sent both Quran and prophet SAWW.
Quran needs correct interpretation.

Quran has all answers


How to make music from using scales?

Question: Been playing guitar for almost 60 years. Still a novice in my opinion.  Been practicing scales and scales and scales.  Looking to unlock music from them.  Listening to Mozart's piano I hear scales behind the music.  For me however, I play scales listening for the music but never hear it.
Comment: Welcome! I'm afraid your meaning isn't quite clear. Can you edit the question to explain more? I could imagine that you might mean: "When I hear scales in real pieces, they're musically expressive; when I practice them they aren't; how can I be more expressive when playing scales?" OR you might mean "I'm improvising or composing my own music and want to know how I can incorporate scales in a more musical way" OR "I'm not incorporating scales per se, but talking about them as a structure 'behind the music,' and I have some kind of question about 'scales' as note collections.'"
Comment: Do you also practice songs or pieces on the guitar? That's the most important ingredient in learning to write: learning to play what's been written by others. Scales and exercises have never helped me write or compose.
Comment: You're listening to Mozart's piano music, but trying to play what style on guitar?
Answer: You're coming at it backward. Scales/Chords are just a collection of colors. A palette of colors doesn't equate to a painting.
Think "melody"...think "statement"...think "conversation"...think "phrase". Just use scales/chords to give you a reference framework which to pull your colors from. A palette.
Also, practicing scales for "technique" is only minimally useful. Work on riffs, licks, ideas, themes, and melodies. Bass is no different than any other instrument in the fact that optimally, your lines should sound interesting on their own.
Answer: "Unlocking music from scales" is not going to happen, I'm afraid. In my opinion that others will perhaps disagree with: scales (and broken chords) are just a kind of "musical oil".
Let me explain. If you have a machine that has various cogs, handles, pistons and so on, you will want the parts to be well oiled, so that it runs smoothly. Similarly, the scales and broken chords are a great device to smoothly connect various sections of music together. If you grabbed two different sections of music and slap them one right next to the other, the result would often be weird. Put a scale between them, and our ears will sort  of "slide" on it, landing safely in the next section.
There are other uses of scales (and broken chords). You can use them as a "filling" (e. g. instead of a single C major chord in the bass held for a long time, you can play many short C's, E's and G's in various combinations to provide more movement), or even as a "firework" — if you want to include a virtuosic quick passage in your music that will naturally fit into the music, scales (and broken chords) are the way to go.
However, by themselves, they do not make music. Continuing my metaphor: you're trying to build a machine, so you buy a huge barrel of oil, and then you're sad that the wheels aren't turning — but the reason is that you didn't buy the wheels in the first place! Scales are good for filling, connecting and adding fireworks, but if you want to write good music, you must first write chunks of music that could be connected, filled up and firework'ed, otherwise it won't have anything to stand on, it will sound "flat", "empty" and boring. The "chunks" will typically be strong melodies and/or good harmonic progressions, so I would say you could look into these things more than into scales.
Comment: "but the reason is that you didn't buy the wheels in the first place!" Maybe. I'd rather say its the driver that is missing, or the fuel, or both. One needs tunes sparkling up in the mind, tunes that want to leave it. Without that drive, music won't tell much to the audience, instrumental music at least.
Answer: I suggest two things to consider:

the difference between scales (step-wise, conjunct motion) moving at a harmonic pace, and decorative scale which combine chord tones and passing tones
the common harmonic associations of scale degrees to particular tonal chords

Compare these two passages which both use full octave scales in the treble...

The first has a chord change with each scale step. Each time the treble moves one step along the scale the chord changes. You can think of this as voice leading. Voices are moved by steps to form new chords. Every step moves to a new essential chord tone.
In the second the scale runs are on beats 1 & 2, but the scales pass through the chords. In bar 1 the C chord has a duration of 2 beats. Some of the scale notes fit the chord and the others pass between those notes. In bar 2 a similar thing happens, but the chord durations are only 1 beat. Those in between passing tones are less harmonically essential that the chord tones so on the whole the scale is mostly decorative. It embellishes the chord.
I highlighted the chord tones in those two passages with blue to make it visually easy to read.
When considering the harmonic versus decorative nature of scale wise movement be aware of octave displacement in the melodic line...

...the first two bars is the previous decorative scale idea but I've labeled the starting note of the scale run and the note it leads to with solfege syllables. I also labeled the bass to show the basic two part voice leading. Notice how the scale runs starts on DO and ends on RE and when specific octave is disregarded that is just a scale step, and it this example it forms a harmonic scale step. The second two bars reduce the scale run to just the implied harmonic movement. The use of the scale there is less about the melodic line and more about getting 16th note figuration into the passage. You could do this instead...

...and musically very little has changed. It's the same harmonic design, same voice leading, same rhythm. I tried to get the second 16th note group to form a small ascent so it has a bit of the same ascending direction. Only the specific linear contour changes by switching between a straight scale and turning figures. Classical style music does this all the time treating scale runs as just another interchangeable rhythmic figuration option.
When making music - especially when emulating classical style like Mozart's - combine short passages mixing both harmonic and decorative scale play and try using space to shape phrases and create rhythm. Maybe something like this...

Treble part chord tones highlighted blue and Roman numerals to make clear the chords, because some are incomplete or implied. It's not great music, but hopefully serviceable. But the idea is to show mostly mundane scale and step-wise movement assembled to make something musical.
Rhythm, metrical placement, and sense of phrasing are essential to make it really work, but those elements are about the study of harmony and form. Therein may lie the problem. While the concern is about scales their use in classical style is understood through a harmonic framework. Especially when scales are played rapidly in a decorative way you must know what harmonic progression those scales are decorating. In that sense the scale isn't quite generating the music but instead decorate music initially conceived in harmonic terms.
Scale degrees are strongly associated with certain chord. Understanding those associations will help a lot with putting scales and chords together. Perhaps you have heard something like any scale degree can be harmonized as three chords, like this...

Of course those three harmonizations are possible, but it doesn't convey the harmonic associations that are important in classical style. A good way to learn those associations with with the rule of the octave which is a harmonized bass scale, like this...

The rule of the octave is part of the old figured bass tradition and you can find many versions, each slightly different, from various teachers. Notice the harmonization differs depending on ascending or descending direction. You can read up on this and other figured bass ideas to get a better understanding of classical style harmony, but the important point to make is the scale degree, even when played without harmonization, strongly suggest certain harmonies. For example, if you play descending (solfege) FA to MI, it strongly suggests harmony V7 I. Knowing those associations will help play using scales with better musical meaning.
Finally, your focus is on scaled, but don't overlook the importance of rhythm, meter, and the bar line. Just like melody and harmony work together, you need to make those elements with a good sense of rhythm and meter. The basic way to get all these elements working together is accent beat 1 after the bar line with a chord change and a relatively long rhythm value. For quick decorative scale runs the lines race up to the bar line and then take a longer note after bar for beat 1. Like in this example from Mendelssohn's Sinfonia 1 in C...

Of course that isn't the only way to use rhythm, but scales, harmony, and rhythm all confirm the meter and make good musical sense.
That Mendelssohn is four part strings. Maybe a solo line would make a better example, like this Bouree from Bach's Cello Suite III...

...see how the scale runs up to the bar line and longer rhythm after the bar line? Note the figure in the blue box. Rhythmically it's still all eighths, but it's an elaboration of the E♭, notice how that figure starts and ends on E♭, it's a bit like two beats of E♭. The complete melody is complex, but quite a lot of it displays the basic idea of fast scale runs leading up to the bar line.
So, don't just noodle up and down scales.

mix harmonic and decorative scale patterns
makes sure the scales represent good harmonic progression
use good rhythm to express the meter and mark phrases
Answer: Marvelous input from so many fellow players.  I often begin disciplined practices and drift off into extended I IV V patterns and riffing.  An hour later I return from inner space hoping somehow my wanderings have improved my playing a tiny bit.  Fellow players - I'm sure you understand this.
Answer: As you seem to understand, scales aren't music. All they are, in actual fact, is a sequencing of certain notes that are presented in ascending and descending form. Rather like our alphabet is simply all the letters, set out in an order that has become familiar over time.
True, certain pieces will actually have runs of scales in them, up and/or down, but by and large, those small jumps from one scale note to the next, don't constitute melodies. Especially when there are more than three or four in sequence.
By jumping about a bit, other music becomes apparent. Take notes ^1, ^3, ^5 in that order. They make an arpeggio, which again could be used, but sparingly.
An idea: stick with the scale for now, but don't play it as a scale, keeping exact solid timing. Play the notes with gaps between, some long and some short (notes and gaps).You may even stumble on some snippets of familiar tunes!
Take a good look at some of your favourite pieces. Examine where there are scale bits, arpeggio bits, bigger jumps. Look at the large jumps, and often find that the very next note comes back to something in between.
While you're doing that, it may become apparent that when a piece has several bars of something, it's repeated soon after. There's no point in keeping on making up new bits of tune!
That's starters for you. Good luck!
Answer: Ok, here's a hands-on approach in 3 steps. Quick results, with minimal music theory.
1 Assumption
You can come up with a melody, e.g. from humming, singing or playing your strings.
If you know the scale of the melody, use the Scales button in the next section. If not, identify it first by Identify Scale.
2 Scale information
Get the known or identified scale from Chord.Rocks, e.g. for G Dorian. Play your melody for the notes shown in the fretboard on top (i.e. this is your melodies scale).

3 Chords and Cadences
Pick chords from the table Chords in Scale at the lower right. For your reference I put the roman literals to indicate the chords degree in red. Click on any of the blue ones: these use the same notes as your melody scale, i.e. the risk for unharmonic collision in your ear is ... low.
Try different chord sequences (=cadences) with the same melody. Pick the one which pleases you most. You can find popular chord progressions (=cadences) on hook-theory.
That's it. Refine as needed. Violate aboves "rules" from time to time: trust your ears.

How to make music from using scales?


Ubuntu 12.04.3 drivers for Lenovo G500 with i3 3110M CPU

Question: I'm thinking in buying a Lenovo G500 with i3 3110M CPU, I asked Lenovo and they said they don't have drivers for Linux yet and seems G500 is not a certified hardware yet. But I'm pretty sure that there are lot of G500 owners who has already installed successfully Ubuntu 12.04.3 64bits, which drivers you used to install Ubuntu?
Answer: I have Lenovo G500s. All drivers are included in the Linux Kernel. Only for the Graphics card, use this trick. But older Linux Kernel occurs problem with Ethernet driver. But if you update the kernel the driver will be automatically installed. If you use Ubuntu 13.04 or newer then the driver is pre-installed.


Created a font set with inkscape, need help reducing the space between fonts

Question: I created a font set with inkscape, it all worked well, I converted from .svg to .tff, however I tried using the font to type and I noticed that the fonts have huge spaces between them need help reducing the space between fonts. I would need some help or suggestions on what I could do to reduce the space between the fonts.
Comment: What does "between the fonts" mean? Are you referring to space between *letters* or space between *lines* (line feeds)?
Comment: As Scott asked but more bluntly, what are you talking about?

Did you realise, a trained and experienced designer might take a fortnight to complete a font design?
Answer: This is the kerning problem for proportional fonts (different than monospaced fonts). It's not that simple to fix it for the differences between blank spaces of characters. There are some professional font creators like Fontographer or Fontlab with automatic kerning, but is better to check it manually. I'm not sure Inkscape has a font kerning manager feature.
Comment: Inkscape has kerning but I am not sure how to adjust the space with this, in kerning set up, I can see two drop down menus, one labelled 1st glyph and the second labelled 2nd glyph, then there's first unicode range and second unicode range. I am new to using inkscape, so I am not really sure what I am looking at here.
Answer: Here's a gif:
https://framadrive.org/s/kPWdsMZ273qJD2c
You select the two letters between which you want to change the kerning (glyph a = first letter, glyph b = second letter), click on 'add pair', then they'll be added to the list.
Then you select the item in the list, and move the slider.
To make letters appear in the optimal position from the start, position their left borders at a useful distance from each other before you click on 'get curves from selection', i.e. put them directly on top of each other, and align their left edges, and then adjust where they are meant to overlap (if you're making a font that is written left to right, that is).
Comment: I followed the gif tutorial, but I am having some problems, when I click add pair, a white pop up box opens up and it stays that way, I am unable to click anything and when I close the pop up box, inkscape program closes also
Comment: stan, what's your OS and Inkscape version? Any command line output if you start Inkscape via command line (use inkscape.com on Windows)? Could be : https://bugs.launchpad.net/inkscape/+bug/1688746 or https://bugs.launchpad.net/inkscape/+bug/1170002 .


Probability of Choosing Cards out of a Deck of 60

Question: Similar to the standard 52-card deck questions, I have a question about choosing cards; however, I am working with a 60 card deck and I have 4 players. At the end of each game, 1 player will have 15 cards. In this game, there are 10 different "suits" of cards. What are the odds that 1 player will have at least 4 cards from the same suit (each suit has 6 cards)? If possible, express your answer in terms of combinations as well as probability.
Edit 1 So far, I have determined that 15 C 60 (15 choose 60) will get the 15 cards that the player ends up with. Then, I attempted to figure out how many ways I can have 4 cards from the same suit of 6. Think of this as getting 4 hearts or spades in a standard deck. Perhaps the formula is something similar to (15 choose 4)/(60 choose 15)?
Comment: Given that you imply this is the result of a game, rather than a purely random assignment of 15 cards, it is hard to figure out the probability without knowing the game.
Answer: If you are wanting to know the probability that a hand of $15$ from this deck of $60$ has at least $4$ cards from the same suit (i.e. the "game" has nothing to do with it):
Suppose the $10$ suits are $A, B, C, .... J$ There will be many combinations of cards that would meet the requirements, e.g. one of them could be $6A-3C-3F-3H$. Then
$$Pr = {{\binom66\binom63\binom63\binom63/3!}\over\binom{60}{15}}$$
The division by 3! is because there are the same number of cards from 3 suits.
You will need to compute similarly for other combos and add up in the numerator.


Can Crafting be Profitable?

Question: I've got a lot of junk I need to clear out of my inventory. Selling to merchants is all well and good, but can I do any value-add before I unload my packs to increase my rate of return? Are any of the things I can make worth more than simply selling all of the component parts to a vendor?
Comment: In my opinion, no. I feel that crafted items.yield less shards than raw resources used to create them.
Comment: Feeling don't enter into it. It's a question of math that I am too lazy to do, and assume someone else has done!
Comment: I'll be happy to test this next time I play it. But as far as I remember, I've always sold resources because they worth more than potions and traps.
Answer: This is limited to potions and traps. Any kind of ammunition cannot be sold.
As for the value of components vs items, as an example:
A health potion can be sold for 6 shards. However, to make a health potion you need 2 "Rich meat" and 3 "Fatty meat". Rich meat sells for 3 shards per item, and Fatty meat sells for 2 shards per item, meaning that by selling the items, you get double the value of the potion.
The upside is that a lot of the time, Potions and traps are found in loot boxes or treasure boxes, on human enemies, etc. So in those situations, you can fill up your stock of potions and traps fairly quickly, without expending your meat stocks.
As for stocking up on ammo parts - firstly, you can never have too much Ridgewood. If you need to keep things limited, I keep it down to 3 stacks at the very least. For all other items required for ammunition, I keep at least one stack, two stacks if I'm feeling generous (items like blaze, chillwater, sparkers, etc).
Comment: Yeah I'm pretty good on understanding my keep vs. sell quotas and not really asking about that here. Was just trying to figure out if there was any value on turning all my meat into potions or blaze into traps (etc). before turning it into shards at a merchant.

Doesn't sound like the math makes this worthwhile though, so it's time to sell a bunch of meat.

Can Crafting be Profitable?


How to reuse old save games in Dirt after reinstallation?

Question: Does anyone know a way to reuse old save games in Dirt? I've passed almost 3/4 of the game, when I needed a reinstall; I tried to copy old saves to the savegame directory located in C:\Users..., but game always informs, that savegame is broken.
Answer: This is a very, very old problem with Codemasters' racing games.  Sometimes they will become corrupted for absolutely no reason, and they're difficult to recover because they're stored in an encrypted format, to prevent tampering.  Because it would impair the user experience if people could cheat in the single-player portion of the game, obviously!
Anyway, there is no tried-and-true solution that I've ever heard of. Here'a thread where a bunch of people report that making random changes to their settings fixes the problem with F1 2012.
Here's a thread about it happening in Dirt 3, only it was not precipitated by trying to move the files to a new installation.  There's no answer suggested, though.
You can find threads like this on gaming forums everywhere, and there's never really a solution.
Comment: While I understand this is a common problem, this space is reserved for actual answers.  I have removed the information that doesn't relate to solving the problem.
Comment: So I'll just add the information here.
Comment: Some quick googling reveals complaints about this problem for: Grid, Dirt, Dirt 2, Dirt 3, Dirt Showdown, F1 2010, F1 2011, F1 2012.  I imagine when Grid 2 comes out, this problem will remain.  I would suggest staying away from this series.
Answer: If you bought a code for DiRT from Codemasters, and are having problems after a reinstall, I'd suggest you check the DiRT forums, or email Codemasters at email@example.com.
Any other method of acquiring new codes is likely illegal, or a violation of the game's EULA or Terms of Service.


Origin of "s--t-eating grin"

Question: What is the origin of the phrase shit-eating grin? How did it come to mean showing smugness or self-satisfaction of an individual's actions?
Answer: From the Urban Dictionary:

...these uses are documented in the Oxford English Dictionary no earlier than 1957

There have been similar expressions used quite far back:

In Book XXI of his History of Rome, Livy describes a Carthaginian sect of coprophages, the risus faecivorus, or shit-eating grin, being commonly displayed by its adherents.

Although, its origin is undetermined, they may have been incidents which caused the invention of this phrase. Below is an excerpt:

"1944 Jrnl. Nerv. & Mental Dis. XCIX. 959 Among demented patients in
  advanced stages of their illness,..it is not rare to see some of them
  grasp their own feces, chew them and eat them often with great pleasure
  and satisfaction (coprophagia).
Comment: I can recall, about 40 years ago, hearing some nurses who worked at a hospital for mentally disabled discuss various traits of patients, including the eating of feces.  So there may indeed be a literal connection.
Comment: The quote about Livy XXI is pure hogwash -- you shouldn't believe everything you read in the Urban Dictionary!
Answer: The phrase in slang dictionaries
The earliest slang dictionary coverage of the expression that I've been able to find is from Robert Chapman, New Dictionary of American Slang (1986), which offers this entry:

shit-eating grin n phr An expression of satisfaction; a gloating look: Go ahead, sit there with that shit-eating grin on your face—Earl Thompson/ stood there with a smug shiteating grin on his face—Fingered City

Nine years later, Robert Chapman & Barbara Kipfer, Dictionary of American Slang, third edition (1995) changes that basic definition only slightly:

shit-eating (or turd-eating) grin n phr by 1960s An expression of smug satisfaction; a stupid gloating look: [citations omitted]

Jonathon Green, Chambers Slang Dictionary (2008) provides a similar interpretation:

shit-eating grin  n. (also cat-eating grin, crud-eating grin, shit-eating smile) {[from] shit-eating [1940s+, "1 a general term of disparagement 2 sly, duplicitous 3 toadying, subservient"} {1950s+} (orig. US) a smug, self-satisfied smile.

On the other hand, Tom Dalzell & Terry Victor, The New Partridge Dictionary of Slang and Unconventional English (2006) counters with this rather different entry:

shit-eating grin noun a broad smile, ingratiating and unctuous US, 1957 [Citations omitted.]

The Earl Thompson quotation in Chapman's 1986 dictionary seems likely to come from his novel A Garden of Sand (1971), while The Fingered City (1975) is a book by Denison Hatch. If these dates are correct, neither instance that Chapman cites is particularly close to the earliest reported occurrences in print of "shit-eating grin."

Early instances of 'shit-eating grin' and allied phrases, 1957–1961
The earliest confirmed matches for the phrase that I've been able to find in various database searches are from the period 1957–1961. I think it's worthwhile to consider several less taboo versions of the expression from this same period, since these may be instances of censorship-enforced euphemism. Readers can judge for themselves whether these are in fact euphemisms or simply weakly related (or totally unrelated) similar-looking phrases.
From Len Giovannitti, The Prisoners of Combine D (1957) [combined snippets]:

Both men looked up from their potato-peeling job as Bob Rawlins came into the combine and sat down on the bench opposite. He had a a queer grin on his face and Storch and Zukerman knew he was set to spring the latest rumor. Rawlins was the hottest fighter pilot ever born; he was also from Texas. Everybody knew this two seconds after meeting him; and three seconds after meeting him, everyone knew he was the biggest liar ever born. He loved rumors, good or bad, and spent his days living on each new one he heard or could dream up.
"Okay, what's the shit-eating grin for? What's up now?" Storch asked, winking at Zukerman.
Rawlins kept the grin. "You mean you ain't heard?"
"No, we ain't heard, so tell us before you choke," Storch said.

The expression here could very well mean "self-satisfied grin," although it is not altogether clear what sort of "queer grin" the author actually imagines is playing on the character's face. It seems entirely possible that the aspect of the grin that the author is focusing on in this passage is its artificiality, unnaturalness, or forcedness.
From Gene Brown, The Locust Fire (1957) [combined snippets]:

"'Hold up there, Tom," says Pappy.
"The colonel stops like he's been shot in the back. He's a damn fine figure of a man, especially in the dress pinks, with them squared-off shoulders. 'Well?' he says.
" Old Pappy walks around in front of him. I guess the colonel got a good whiff of the juice, because he kind of sways back on his heels. But Pappy steps up close, with a big dirt-eating grin on his face, and starts running his hands up and down the lapels. Then he flicks a little imaginary dust off the colonel's epaulets and moves back a pace. "That's a real pretty suit, Tom,' he says. 'Ain't it a pity all these poor hungry boys here can't be wearing one just like it?'"

Whatever the "dirt-eating grin" looks like here, a grin of satisfaction or gloating doesn't fit the context particularly well. Pappy is drunk, so his grin may be good-humored in a sloshed way, or it may be simply goofy, or it may be inappropriately familiar. Certainly, his conduct is insubordinate and highly offensive to the colonel.
From Hubert Selby, Last Exit to Brooklyn (1957):

He [Spook] picked up a old police bike for  few bucks and fixed it up. You know, threw some paint on it and stole a wildass buddyseat all covered with fur and chrome, and was fulla piss and vinegar ta go. We toldim ta play it cool and relax and celebrate Tommys marriage. But he flipped when someone tried ta get that goddamn hat off his head so we said OK, wed go downstairs and look at his bike. So we looked. Big deal. Yaknow, when the cops is finished with a bike, man, its had it. But it was a bike and it moved. I think that sonofabitch woulda used it even if he had ta push it or pedal it like a kiddy car. So he kicks it over after 5 minutes and we listen to it cough and miss and Spook went puttin off with a shiteatin grin on his face and we went back up stairs and a few minutes later he comes back. Smilin all over the goddamn place and the strap of his hat under his chin. I tellya man, it was a pissa.

This is may be the 1957 quotation that most sources have in mind when they date "shit-eating grin" to 1957, although it is not the only instance from that year (as noted bove). Still, the sense of the phrase aligns reasonably well with the definition in Dalzell & Victor: "a broad smile, ingratiating and unctuous"—with the "broad smile" part, anyway.
From Evan Hunter, Strangers When We Met (1958):

Altar was smiling, but the smile was a crud-eating one, and Larry's years in the service had taught him to recognize the crud-eating grin and to know what it usually preceded. He felt himself stiffening.
"Sit down," Altar said. "Want a drink?"
"No." Belatedly, he added. "Thanks."
"Well, sit down anyway."
"Sure." Larry sat in the easy chair to the left of the bar unit, facing the blue couch upon which Altar still sprawled.
"I don't like to do this," Altar said. "I don't like it when it's done to me, and Christ knows it's done often enough. But I think there's a difference here, and if I'm wrong I'll apologize. Can I talk to you like  man, Larry? Or do I have to give you the schmaltz?"

Here, the "crud-eating grin" seems to be a kind of grimace of forced conviviality preceding the imparting of bad news (in this case, the bad news is that Altar thinks that Larry's rough sketches "stink").
From Thomas Williams, Town Burning (1959):

"...A man killed my dog, that's all I know! Daisy, she was the sweetest little dog you ever see. She never hurt nobody, except rabbits. She was all hell on rabbits. Shot forty rabbits front of Daisy one year. I damn near lived on rabbits that year. You ought to heard Daisy on a hot trail. Ki Yi Yi! Jesus! Wouldn't she go right out straight? Daisy'd dream about rabbits. Sometimes she'd wake right up out of her sleep a-running and a-yelling! Right after them rabbits, right out of her sleep! You'd see her little legs begin to twitching and her nose to puckering. Didn't she look ashamed to herself when she woke up! She'd look all around pretending they was a rabbit under my bed. I'd look down at her and grin, then she'd look up at me and give a shit-eating grin and go back to sleep. Damnedest dog."

The grin described here appears to far more sheepish than smug, since it involves being caught in a failed attempt at subterfuge.
From Richard Bissell, Good Bye, Ava (1960) [combined snippets]:

"Be quiet," I said. "You and your big mouth. You oughtta go with a good side show. 'Ryan and his crooked crew!' Why you are likely to end up riding out of town feet first."
"Maybe so, but I'll have company. I'll nail a few of them to the tan-board before I go. God damn it, Frank, somebody's got to do something. You don't care. Oh no. You just stand there with that shit-eating grin. Very funny. You don't care if they come with bulldozers, dredges, pile-drivers, tanks, machine guns! You just keep asmiling and agrinning like it was all a Sunday school picnic out at Riverside Park. By God, what would it take to wipe that foolish smile off your face?"

The character who introduces the expression "shit-faced grin" in this exchange goes on to refer to he other person's "foolish smile," suggesting that the grin is less smug than ill-suited to the occasion.
from an unidentified piece by Ivan Gold in The Noble Savage (1961):

The corporal has been back since, wearing a shit-eating grin and parrying attempts to get the whole story. Poor Pop has never returned. I, on my part, have come by a story which rounds out my repertoire, this tale of intrigue during the Fourth Moon ; it bristles, I think, with a peculiar significance. Don't you ... "

A possible antecedent phrase: 'shingle-eating grin', 1949–1950
An earlier variant found in military periodicals is "shingle-eating"—which may invoke (for purposes of euphemism) the phrase "shit on a shingle," meaning creamed chipped beef on toast, a common entree during World War II.
From an unidentified article in The American Legion Magazine (1949):

No work of typewriter or camera is complete without The Homesick Kid from Kansas. When this lad appears at camp, he brings with him wide blue eyes, a butch haircut, a shy, shingle-eating grin, and a firm conviction that no real bullets will be used. The Kid wanders about telling the others how different Army life is from life on the farm in Kansas. He confides that he has joined up to fight for Ma's apple pie and an ice cream soda at the corner drug store. He fights in vain, however, since the pie is sent to Okinawa by mistake, and there are no corner drug stores where his battles are fought.
The main thing about the Kansas Kid is his inability to learn anything. He is the only person in the world who can go through a year of intensive training and tome out with his blue eyes as wide and blank as when he started. He never learns the simplest facts of military life, and is vague, dreamy, confused, stupid and homesick from the time he is drafted until he is knocked off.

The sense of "shingle-eating" as used in this excerpt is something like "bashfully stupid."
And from an unidentified piece in The Leatherneck (December 1950):

... Mason...! You O.K.?"
"Yeah, O.K. ... I guess," Herb yelled, looking himself over for the first time. "O.K.," he added again a big shingle-eating grin spreading over his face. The soft earth moved easily under him as he rolled over on his back . . . pleasant, sweet, fragrant. Inside his field shoes his toes wriggled gleefully. Through a newly made crack in the sandbags he could see the setting sun, no ordinary sun.

As in the previous example, the sense of the phrase here seems to be "goofily uncertain smile"—not smug, self-satisfied, or gloating.

Conclusions
It seems clear from the slang dictionary definitions noted at the beginning of this answer that "shit-eating grin" has been applied to a fairly wide range of states of mind behind a grin so characterized: satisfaction, gloating, smugness, stupid gloating, self-satisfaction, ingratiation, unctuousness, slyness, duplicity, toadying, subservience. To these, on the basis of how the expression was used in the late 1950s, we might reasonably add shyness, bashfulness, awkwardness, foolishness, sheepishness, naïveté, forcedness, artificiality, false conviviality.
It is not at all clear to me that the earliest instances of "shit-eating grin" are intended to convey the sense of smug self-satisfaction that later lexicographers attribute to the phrase. The smug sense of "shit-eating grin" may have been a later development or it may simply represent one line of usage of an inconsistently understood expression, coexisting with such alternative senses as "sheepish grin," "awkward, self-conscious grin," and "uneasy or artificial forced grin."
How you assess the original expression's meaning depends to a great extent on the weight you give to "shingle-eating grin" as a possible antecedent or euphemistic early form of the phrase. If "shit-eating grin" emerged as G.I. slang during World War II and first appeared in print in the bowdlerized form "shingle-eating grin" in U.S. military publications, the two examples of "shingle-eating grin" cited above from 1949 and 1950 are highly relevant. The tenor of those two examples—especially the one from 1949—strongly suggests that the phrase may originally have applied to a grin that expressed shyness, naïveté, an awkward eagerness to please, and a kind of unguarded gullibility.
At least three instances of "shit-eating grin" from the late 1950s make sense when read in that way. Most notably, the Selby quote from 1957 (with the character's childlike delight in his surplus police motorcycle), the Williams quote from 1959 (with the dog's goofy attempt to validate or normalize in the waking world her excitement at chasing rabbits in her dreams), and the Bissell quote from 1960 (with the speaker's explicit characterization of the "shit-eating grin" with a "foolish smile") are thoroughly intelligible when read in this sense.
But the "eagerness to please" element of the Homesick Kid from Kansas's "shingle-eating grin" in 1949 might also have evolved into a contrary sense of "shit-eating grin"—one that emphasized toadying, smarmy unctuousness, and artifice. We see early instances of this line of meaning in the Hunter quotation from 1958 (in which the character with the "crud-eating grin" is trying to project conviviality in a forced manner) and (arguably) in the Gold quote from 1961 (where the grinning corporal parries all attempts to get the true story of some incident from him).
A third line of usage emphasizes smugness or gloating. The strongest instance of this usage seems to be the one in the Giovannitti quote from 1957 (in which an airman who loves to spread rumors relishes the moment of being in possession of a juicy story that his hearers are not already acquainted with); it may also be an element in the Gold quote, as artificiality and smugness are quite capable of shading into one another.
Today, the smugness line of meaning seems to be dominant, perhaps owing in part to the reinforcing influence of slang dictionary definitions. But as the Dalzell & Victor entry for "shit-eating grin" indicates, the ingratiating unctuousness and simple-minded broad grin senses of the term may still have some currency as well.
Answer: From what I understand, dogs would often follow horse-drawn wagons and eat the horse droppings. The taste caused the dogs to raise their heads and pull their mouths back in a sort of grin.

Origin of "s--t-eating grin"


Are big checks (dimensions, not money) valid?

Question: You've probably seen the really big checks given to winners of monetary prizes. Are these checks valid?
Answer: In the mid 80's, I wrote a check to the IRS and sent it along with my tax form.
The check was hand written on a white msn's dress shirt. As I recall, the IRS cashed it, and the bank charged me $5 or $10 for using a non-standard check.
Answer: Let's assume the oversized checks aren't  valid. That means the people giving you the prize gives you a standard check after they take the picture.
The oversized checks are a prop. They are for PR purposes.
If you look at thr pictures the big checks are missing the name of a bank. They also don't include an account number. Your bank won't cash them or accept them for deposit.
Answer: The ones you are referring to probably aren't. But there is no reason an oversized check couldn't be valid as long as it had all the proper information on it and the bank can verify that the owner of the account intended to transfer money to you.
Answer: Banks are no longer expected  to accept checks that can not be scanned by their standard machines. This changed in the last few decades. See my other answer today.


Deviation from Hardy Weinberg equilibrium (HWE)

Question: I have a set of 10 genes, each gene contains around 15 SNPs. I have tested the deviation from Hardy Weinberg equilibrium (HWE) for all SNPs. All of the SNPs didn't deviate from HWE, except 5 SNPs in ABCG8, they had p<0.05. I have found different factors that can affect the HWE. My question: Why for the rest of the SNPs met the HWE, why only 5 SNPs in ABCG8 deviate largely from HWE?
Comment: Be careful with the claims based on p-values: **a p-value allows to reject the null hypothesis, but not to confitm it**. In other words, when $p<0.05$ one can say that HWE is broken, however $p>0.05$ does not mean that HWE holds - it could be still broken, but we cannot prove it.
Comment: I would quibble with @Vadim a bit- when you do 150 tests, you expect that $0.05 * 150 = 7.5$ SNPs to be $p < 0.05$, as under the null hypothesis, p-values from independent tests are uniformly distributed. P-values are a quite low standard of evidence except when they're very small. Having all 5 occur in one gene might be surprising, but nonetheless I would say that "rejecting" the null hypothesis based on it is a bit strong, as the observations are still pretty consistent with the null hypothesis (without seeing additional data).
Comment: @Vadim ok, that makes sense. I agree with your overall point about p-values used to confirm the null hypothesis, I think I was just worried about the other side of the issue, which wasn't clear. I think that you actually addressed the question quite directly and accurately! I would suggest making it into an answer, actually.
Comment: @MaximilianPress I was talking about more basic difference about p-value and power, objecting the claim that *the rest of the SNPs met the HWE*. However I do agree with you that, given the large number of tests, even the five SNPs with $p<0.05$ are not a proof that HWE is violated.
Answer: A significance test (i.e., p-value) allows us to reject the null hypothesis, but not to confirm it. In other words, when $p<0.05$ one can say that the conditions for HWE are not met, however $p>0.05$ does not mean that HWE holds - the conditions might still not be met, but we cannot prove it. Thus, by making statements such as All of the SNPs didn't deviate from HWE and the rest of the SNPs met the HWE one may be committing Type II statistical error.
As @MaximilianPress correctly pointed out, in this case one should not be making any statements about the SNPs with $p<0.05$ either, due to the high possibility of False discovery. Indeed, a p-value gives us the probability that the data would be at least as extreme as was observed, even though the null hypothesis is true. Given $N=150$ SNPs one expects about $$N\times\alpha = 150 \times 0.05= 7.5$$ statistically significant outcomes to occur by chance, even if the HWE holds. That is, one could be also committing the Type I error of rejecting the null hypothesis, when it is true. To exclude this error one needs to use a more stringent test, e.g., Bonferroni correction, i.e., testing against the significance level $N$ times smaller than the current $\alpha=0.05$:
$$
\alpha\longrightarrow\frac{\alpha}{N}=\frac{0.05}{150}\approx 0.0003
$$


What jurisdictions, if any, have preemptive judicial review of bills or laws, without a suit being brought challenging the law?

Question: In the US, a court typically can only review a law if a case is brought, which generally requires a plaintiff with standing to sue. I seem to recall that some other country or countries have a system allowing for judicial review of laws/bills without waiting for such a case to be brought. What countries, jurisdictions, or legal systems allow for such preemptive review? What are the advantages and disadvantages?
Related: Why has the Supreme Court of the United States not used its power of judicial review to audit constitutionally-questionable laws like the Patriot Act?
Comment: My concern is that this question is kind of open ended. Potentially a lot of things could be listed. DJClayworth gave an example, and in some states, changes to election laws require judicial review beforehand as well.
Comment: Also, excuse the plug, but I think reasonably related: http://politics.stackexchange.com/questions/1702/congress-delegating-statutory-rewriting-power/
Answer: In Canada at least the Government can ask the Supreme Court for its opinion on the constitutionality of any legisation - often before the legislation is adopted. This is called a Reference to the Supreme Court, and has been used several times - most recently to establish the constitutional requirements for Senate reform.
Answer: Germany has the Federal Constitutional Court (Bundesverfassungsgericht). According to Wikipedia (emphasis mine):

Specifically, it can vet the democratic and constitutional legitimacy of bills proposed by federal or state government, scrutinise decisions (such as those relating to taxation) by the administration, arbitrate disputes over the implementation of law between states and the federal government, and (most controversially) ban non-democratic political parties.

And from this blog about one particular law:

Once the law has passed the parliament's upper house in a few weeks – a vote seen as all but assured – the bill will be presented to the German president Joachim Gauck for signature. If he believes the law is unconstitutional, he could either decline to sign it, or sign it, but at the same time ask the German constitutional court to verify its compliance with German Basic Law. Upon signature, the legislation will enter into effect, which then, of course, would still leave the law open to subsequent court challenges.
Answer: Acts of Dáil Éireann (the Irish Parliament) do not become law until signed by the president. The president can, if he wishes, first refer the Act to the Supreme Court to check that it does not conflict with the constitution. A few laws have been blocked that way.
This is not an automatic check that all laws pass through; it is an optional one, held at the discretion of the president.
Answer: In Russia any new law requires expert approval by th Ministry of Justice. It is not exactly a court but they exactly screen the law for contradictions with the existing laws. Often they make points on what should be fixed so it to pass.
Answer: The difficulty is that in many cases the courts have to balance the specific facts of a given case in order to test constitutionality. Absent such a case do we speculate on incredibly unlikely scenarios where a particular law may be deemed unfit? Or under what future circumstances it may be so deemed?
Oftentimes rather than a pure decision, instead legislatures may have a local legal group to look over a law for areas where they fell a judge MAY have issues with it.
Don't forget, in western jurisdictions the legal system is as much about the precedence of prior interpretation and/or application of a given law as much the written law itself.
And finally, judges / lawyers are not overly fond of giving opinions on how they might rule should a certain circumstance of a specific crime be brought before them as it implies a pre-prejudiced position on the law that may force them to recuse themselves from actually judging it for real. So if they say "yeah, I can see where someone could convince me that it is unconstitutional", they will not actually be able to sit on a real case of it as they have a pre-formed opinion. As such, it may hamper their advancement.