I would like to make a small animation :
1-We start with a random distribution of gray points :
Graphics[{
Black, Rectangle[{-2, -2}, {2, 2}],
Gray,Point /@ RandomReal[{-2, 2}, {4000, 2}]},
PlotRange -> {{-2, 2}, {-2, 2}}]
2-Then I would like that those points progressively color themselves to obtain the following :
Graphics[{
Black, Rectangle[{-2, -2}, {2, 2}],
Pink,Point /@ RandomReal[{-2, 2}, {1000, 2}],
RGBColor[.4, .4, 1],Point /@ RandomReal[{-2, 2}, {1000, 2}],
Green,Point /@ RandomReal[{-2, 2}, {1000, 2}],
Yellow,Point /@ RandomReal[{-2, 2}, {1000, 2}]},
PlotRange -> {{-2, 2}, {-2, 2}}]
Ideally : -the points progressively adopt the color. All at the same time, at the same rate (2 seconds ?) -OR each points suddenly change color but just 100 at a time.
3-Finally, once the point are colored i would like to see them move, to join their piers like such :
normalRDN[μ_, σ_, No_] :=
RandomVariate[NormalDistribution[μ, σ], No]
Graphics[{
Black, Rectangle[{-2, -2}, {2, 2}],
Pink,Point /@ ((normalRDN[#, .5, 1000] & /@ {-1, -1})\[Transpose]),
RGBColor[.4, .4, 1],Point /@ ((normalRDN[#, .5, 1000] & /@ {-1, 1})\[Transpose]),
Green,Point /@ ((normalRDN[#, .5, 1000] & /@ {1, -1})\[Transpose]),
Yellow,Point /@ ((normalRDN[#, .5, 1000] & /@ {1, 1})\[Transpose])},
PlotRange -> {{-2, 2}, {-2, 2}}]
I am not sure of the means available for doing such animations, thus my illustrative codes might not be relevant.