title: Creating y shape random float array in J
body: <p>I am trying to creating y shape random float array, and this is my current right now:</p>
  
  <pre><code>input_dim =: 2
  hidden_dim =: 16
  
  0 ?@$ ~ (input_dim, hidden_dim) 
  
  0.838135  0.96131 0.766721 0.420625 0.640265 0.683779 0.683311 0.427981 0.281479 0.305607 0.385446 0.898389  0.24596 0.452391 0.739534 0.973384
  0.914155 0.172582 0.146184 0.624908 0.333564 0.132774 0.475515 0.802788 0.277571 0.146896  0.40596 0.735201 0.943969 0.259493 0.442858 0.374871
  </code></pre>
  
  <p>It seems like this code returns what I exactly want, so I tried to make a function like below:</p>
  
  <pre><code>rand =: 0 ?@$ ~
  </code></pre>
  
  <p>but <code>rand (input_dim, hidden_dim)</code> gives me a syntax error...</p>
  
  <p>I think I am missing one very important part, but I am not sure what that is. </p>
  
  <p>Any advice would be grateful!</p>