Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Here is my code:

data = Table[{i, j, RandomInteger[{1, 10}]}, {i, 5}, {j, 5}];
thePlot = ListPlot3D[Flatten[data, 1], InterpolationOrder -> {0}]

How can I make the data at one point, say (3,4), a different color. I want to highlight that data.

share|improve this question
    
Welcome to Mathematica.SE! I suggest the following: 0) Browse the common pitfalls question 1) As you receive help, try to give it too, by answering questions in your area of expertise. 2) Read the faq! 3) When you see good questions and answers, vote them up by clicking the gray triangles, because the credibility of the system is based on the reputation gained by users sharing their knowledge. Also, please remember to accept the answer, if any, that solves your problem, by clicking the checkmark sign! – Dr. belisarius Mar 8 at 17:43
SeedRandom[69];
data = Table[{i, j, RandomInteger[{1, 10}]}, {i, 5}, {j,  5}];      
ListPlot3D[Flatten[data, 1], InterpolationOrder -> 0, 
          ColorFunctionScaling -> False, 
          ColorFunction -> Function[{x, y, z}, 
                            If[ChessboardDistance[{x, y}, {3, 4}] <= .5 && 
                               z == Last@data[[3, 4]], Red, Blue, Green]]]

Mathematica graphics

share|improve this answer
thePlot = 
 Show[ { ListPlot3D[Flatten[data, 1], InterpolationOrder -> {0}], 
   Graphics3D[{Red, 
     Cuboid[# - {0, 0, 1/100}, # + {1/2, 1/2, 1/100}] &@
      Flatten[data, 1][[3]]}]
   }]

enter image description here

share|improve this answer
    
your solution is robust. – garej Mar 8 at 6:35

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.