MathGroup Archive 2009

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Freeze Panes in Grid Expression

  • To: mathgroup at smc.vnet.net
  • Subject: [mg105125] Re: [mg105060] Freeze Panes in Grid Expression
  • From: Bob Hanlon <hanlonr at cox.net>
  • Date: Sat, 21 Nov 2009 03:37:11 -0500 (EST)
  • Reply-to: hanlonr at cox.net

scrollMatrix[m_?MatrixQ, rows_Integer, columns_Integer] :=
 Module[{
   nC = Min[columns, Length[m[[1]]]],
   nR = Min[rows, Length[m]]},
  Manipulate[
   Grid[
    Drop[m[[1 ;; r + nR - 2]], 2 ;; r - 1]
     [[All, {1, Sequence @@ Range[c, c + nC - 2]}]],
    Dividers -> {{False, True}, {False, True}}],
   {r, 2, Length[m] - nR + 2, 1},
   {c, 2, Length[m[[1]]] - nC + 2, 1}]]

m = Array[a, {15, 10}];

scrollMatrix[m, 10, 5]


Bob Hanlon

---- Thomas Melehan <tpmelehan at me.com> wrote: 

=============
Folks: I often generate a 2D matrix that I would love to be able to view in Mathematica as one does in say Excel, by freezing the window at a certain column and scrolling thru the rest of the columns to the right of the frozen column.  I can take the expression and dump it into Excel but it is somewhat time consuming.  Does anyone know how to directly achieve this in Mathematica, by say using two panels?




  • Prev by Date: Re: MatchQ, silly question
  • Next by Date: Flat attribute and order of function definitions
  • Previous by thread: Freeze Panes in Grid Expression
  • Next by thread: Filling in ListPlot