How to construct poststratification data

in page 389 of stan user, poststratification data p is defined a array[4,5,50]. i wonder how to construct so array with multiple dimensions.
i established a dataframe with dimension (744,5) using SRP::getSyntheticPSFrame and sampling is not done.

my data block is

data {
  int<lower=0> N;
  array[N] int<lower=1, upper=6> age;
  array[N] int<lower=0, upper=1> gender;
  array[N] int<lower=11, upper=65> state;
  array[N] int<lower=0, upper=1> urban;
  array[N] int<lower=0> y;
  array[6,2,31,2] int<lower=0> P;
}

the error is as follows:

Error : Exception: mismatch in number dimensions declared and found in context; processing stage=data initialization; variable name=P; dims declared=(6,2,31,2); dims found=(744,5)
any help is appreciated.

I have settled the issue. thanks deepseek.