I would like to colour individual cells of a table based on quantity. For example if the cell value is &lt;5 then the colour should be green. if &gt;5 but less than 10 should be orange, and red for if the cell is 10. Any ideas? The only solutions I have found colour the entire column/row. Thanks for the help, My following code for the table is: \begin{table}[ht]     \centering     \setcellgapes{3pt}     \makegapedcells \begin{tabularx}{\linewidth}{|*{8}{C|} }     \hline \makecell{Mean\\ Partnership\\ Duration}     &amp; \multicolumn{7}{c|}{The number of simulations resulting in an epidemic out of 10 for mean degree}\\ \cline{2-8}     &amp; 0.2 &amp;0.4&amp; 0.6 &amp; 0.8 &amp; 1.0 &amp; 1.2 &amp; 1.4\\ \hline 100   &amp; 0 &amp; 0 &amp; 0 &amp;  3 &amp; 8 &amp; 10 &amp; 10\\ \hline 80   &amp; 0 &amp; 0 &amp; 1  &amp; 3 &amp; 9 &amp; 10&amp; 10\\ \hline 60   &amp; 0 &amp; 0 &amp; 2 &amp; 8 &amp; 9 &amp; 10&amp; 10\\ \hline 40   &amp; 0 &amp; 2 &amp; 5 &amp; 8 &amp; 10 &amp; 10&amp; 10\\ \hline 20   &amp; 0&amp; 8  &amp;  9 &amp; 9 &amp; 10 &amp; 10&amp; 10\\ \hline 10 &amp; 0 &amp; 8 &amp;  9 &amp; 10 &amp; 10 &amp; 10&amp; 10\\ \hline \end{tabularx} \caption{The number of simulations that resulted in an epidemic for a certain mean partnership duration and mean degree} \label{My table}     \end{table}
I viewed in this post  a solution to my question, but...    Are there any easier way (or alternative) to do this using colors?  Thank you. ------------------ edited after showed than it´s duplicate ------------- I think that there are many sols, but for example this is easy using a normal table without pgf...     I´m trying to adapt to similar colors to apply to the table probabilitiess
Force Messages to use SMS for specific contact rather than iMessage? Essentially, I would like to set my phone so that all my outgoing messages to a specific friend, with whom I currently text back and forth over iMessage, are sent out over SMS, never iMessage. Additionally, I would like to block any incoming iMessage texts of his and (hopefully) they'll fail and be resent via SMS.  Let me restate that: I would like to force SMS for both parties, going both ways, for a specific individual contact.   Is this possible? Blocking any usage of iMessage between myself and this other individual, so they must either send and receive any texts to or from me via SMS (or the texts fail/never arrive). Can I use a 23 W CFL in a fixture that's rated for a 60 W incandescent? I have a lamp that is rated at 60 Watts for an incandescent bulb with a disclaimer to use a 13 Watt bulb instead when using a CFL replacement. Do I really need to respect that disclaimer? Would not a 23 Watt CFL be just as safe to use? It still draws less power than a 60 Watt incandescent, right? Database design for products with bundles of products Will my Chinese visa still be valid if I renew my passport? Will my Chinese visa still be valid if I renew my passport? If so how does that work?  I have heard that you can travel with your new passport and just show the old passport with the valid visa when entering China. Has anyone done that? Recently?   I have also been told that you have to get a new visa, which seems somewhat logical but frustrating, especially when my Chinese visa is only a few months old.  My Chinese visa was issued in late Nov 2014 and I heard the rules changed between the US and China. My visa says it's good for 10 years and my US passport expires in 5. Python provides the "*" operator for unpacking a list of tuples and giving them to a function as arguments, like so:  args = [3, 6] range(*args)            # call with arguments unpacked from a list   This is equivalent to:  range(3, 6)   Does anyone know if there is a way to achieve this in PHP? Some googling for variations of "PHP Unpack" hasn't immediately turned up anything.. perhaps it's called something different in PHP? Set the QGIS display to show decimal degrees? Using QGIS 2.6.1 Brighton. I am trying to set the CRS for the project to display Decimal Degrees, where it is defaulting to Feet. I can change it in the Properties Dialog, but it does not change it, it is just staying on Feet. How do I change it?  Edit: this layer was imported from a shapefile where it was internally set to Feet. I was able to get the vendor to supply one with Decimal Degrees so my problem is gone. Still would love to know if there was a way to do it myself from within QGIS. Booking travel tickets for visa without paying? How to associate multimedia keys to Foobar2000? Does $x^2 - y^2 = 12345678$ (x,y are integers) have any solutions? How to get time difference in minutes in PHP How to disable pylint 'Undefined variable' error for a specific variable in a file? Why are my sauces splitting? Recently all my attempts at sauces are splitting and I'm not sure what's going wrong. Tonight I tried a balsamic vinegar reduction / chicken stock / pan juices recipe to go with my lamb chops, but once again the dreaded split occurred. My wife is patient and forgiving, but I feel like I must be missing something fundamental to get this wrong so often.  Two questions.   What could I be doing wrong to cause these sauces to split? What can I do to recover when it happens again?   UPDATE: The Pan juices contained a tbsp or two of olive oil, and some of the fresh herb rub I'd coated the lamb chops in (thyme, rosemary, and mint). I did not drain the pan before starting the sauce. It has crossed my mind that perhaps there was too much oil / fats in the pan at that point?  For completeness, I should point out that I also sauteed some chopped shallots in the pan juices immediately before adding the vinegar. "Whether" Vs. "If" Could someone please help me with these sentences? I need to know  Which one doesn’t sound natural? Which one is formal and which one is not?   A - I don’t know whether this word fits in the sentence. B - I don’t know if this word fits in the sentence.   C - I don’t know whether or not this word fits in the sentence. D - I don’t know if or not this word fits in the sentence.   E - I don’t know whether this word fits in the sentence or not. F - I don’t know if this word fits in the sentence or not.  For me only D doesn't work and sounds not idiomatic. Meanwhile for me all of these sentences can be used in both written and spoken languages. Do you confirm me? Suppose a particle only influenced by gravity is going from point a to point b on an x,y plane. Is there an equation in which the particle takes the longest amount of time, yet still makes it to point b? I know the equation for brachistochrone is the parametric for an inverted cycloid, yet I'm not sure of the opposite. For reference, I am a high school student wanting to try this for a research project. I really only need to know whether this has already been done or not, but attempted solutions are obviously appreciated. Extracting matrix rows when one of its elements is part of a list (without a loop) Detecting EOF in C++ from a file redirected to STDIN Change default shell for Terminator When is "seems to be" used instead of "seems"? The baby seems happy/comfortable. The baby seems to be happy/comfortable.   Are these both correct? If both are correct, what are the differences between them? How does the drift velocity of electrons in a conductor depend on the temperature? How does the drift velocity of electrons in a conductor depend on the temperature?  I have two contradicting views for this.    First, we can say that increasing the temperature of the conductor will increase the kinetic energy of the electrons. Hence, their drift velocity should increase with increase in temperature.  Or, from the relation $v_d = \frac{eE}{m}T$ ($T$ is the relaxation time) we can say that the drift velocity is directly proportional to the relaxation time. Increasing the temperature will obviously decrease the relaxation time - as collisions will become more frequent - and thus decrease the drift velocity. Hence, an increase in the temperature will cause a decrease in the drift velocity.   So which view is correct? I'm currently using an entry-level DSLR with 18-55mm lens and having great trouble trying to creating a blurred background effect in my photos. Now matter what aperture or shutter speed I choose, I'm not able to get it.  There's a general question about , but what specific things can I do to get this effect with an entry-level lens?