KX Community

Find answers, ask questions, and connect with our KX Community around the world.

Home Forums KX Academy advanced capstone project 1.4

  • advanced capstone project 1.4

    Posted by masmail on April 17, 2024 at 11:24 am

    I’m getting a “rank: Invalid rank or valence (parameter count)” when running this code for 1.4. everything seems to be fine apart from the last line 🤷‍♂️

    eventData:select from event where date=2020.01.02
    sensorData:select from sensor where date=2020.01.02
    lap:.f1.createLapTable[eventData;sensorData];
    f1DbPath:`:./f1/;
    lap:update `sym$sensorId from lap;
    .Q.dpft[f1DbPath;lap;2020.01.02;lap;sensorId];
    megan_mcp replied 1 month, 1 week ago 2 Members · 1 Reply
  • 1 Reply
  • megan_mcp

    Administrator
    April 17, 2024 at 11:52 am

    Hi @masmail

    I believe this error is due to the way you structured your .Q.dpft function.

    If you take a look at the screenshot provided you will see that this namespace only accepts 4 arguments;

    • d is a directory handle
    • p is a partition of a database
    • f is a field of the table named by t below
    • t the name (as a symbol) of a simple table whose columns are vectors or compound lists

    The first two parameters are correct [f1DbPath;2020.01.02, ..] however you need to take a look at the order of your second two.

    Let me know if this helps!

    Thanks,

    Megan

Log in to reply.