KX Community

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

Home Forums KX Academy Developer Level 2 Capstone 5.3 test problem

  • Developer Level 2 Capstone 5.3 test problem

    Posted by karce on September 22, 2024 at 7:37 pm

    Hi

    This is what I got on the 5.3 exercise:

    edgeProfileFull

    option_id | numTrds avgEdge minQty maxQty inst_id opt_type strike expiry inst_syb inst_name
    -----------------| ----------------------------------------------------------------------------------------
    KO20201120C40 | 1 89.0492 69 69 7 C 40 2020.11.20 KO "Coca-Cola"
    TSLA20201120P1400| 1 2.277078 18 18 8 P 1400 2020.11.20 TSLA "Tesla"
    TSLA20210120P1800| 2 121.0842 51 72 8 P 1800 2021.01.20 TSLA "Tesla"
    KO20200720P55 | 2 207.4781 48 78 7 P 55 2020.07.20 KO "Coca-Cola"
    KO20201120P40 | 1 247.01 53 53 7 P 40 2020.11.20 KO "Coca-Cola"
    KO20200920P50 | 1 225.2656 53 53 7 P 50 2020.09.20 KO "Coca-Cola"
    FB20201120C230 | 3 39.75295 9 51 9 C 230 2020.11.20 FB "Facebook"
    KO20200720P60 | 3 67.84031 8 38 7 P 60 2020.07.20 KO "Coca-Cola"
    KO20201120C45 | 3 113.4787 27 50 7 C 45 2020.11.20 KO "Coca-Cola"
    TSLA20200720P1700| 2 225.7795 55 74 8 P 1700 2020.07.20 TSLA "Tesla"
    FB20200920P270 | 3 32.29317 31 64 9 P 270 2020.09.20 FB "Facebook"
    KO20200720C45 | 2 88.92442 66 86 7 C 45 2020.07.20 KO "Coca-Cola"
    TSLA20200920C1500| 2 281.5859 75 86 8 C 1500 2020.09.20 TSLA "Tesla"
    TSLA20210120P1500| 1 -2.497596 5 5 8 P 1500 2021.01.20 TSLA "Tesla"
    TSLA20210120P1600| 1 0.5403304 2 2 8 P 1600 2021.01.20 TSLA "Tesla"
    TSLA20200720P1400| 2 28.83632 80 90 8 P 1400 2020.07.20 TSLA "Tesla"
    KO20200720C40 | 1 413.4723 90 90 7 C 40 2020.07.20 KO "Coca-Cola"
    TSLA20200720C1600| 1 -25.75424 76 76 8 C 1600 2020.07.20 TSLA "Tesla"
    TSLA20200920P1400| 3 159.8536 58 78 8 P 1400 2020.09.20 TSLA "Tesla"
    FB20200920C240 | 3 141.8679 55 92 9 C 240 2020.09.20 FB "Facebook"
    TSLA20200720C1400| 1 145.382 46 46 8 C 1400 2020.07.20 TSLA "Tesla"
    FB20200720P240 | 1 225.6412 81 81 9 P 240 2020.07.20 FB "Facebook"
    KO20200720P40 | 2 43.74333 32 90 7 P 40 2020.07.20 KO "Coca-Cola"
    KO20200920C60 | 1 240.0101 76 76 7 C 60 2020.09.20 KO "Coca-Cola"
    TSLA20201120C1700| 2 162.5249 53 92 8 C 1700 2020.11.20 TSLA "Tesla"
    FB20200920C260 | 5 15.01372 35 52 9 C 260 2020.09.20 FB "Facebook"
    FB20200920C230 | 2 88.54873 26 33 9 C 230 2020.09.20 FB "Facebook"
    TSLA20200920C1400| 2 180.0777 65 80 8 C 1400 2020.09.20 TSLA "Tesla"
    TSLA20210120P1400| 2 86.17815 59 61 8 P 1400 2021.01.20 TSLA "Tesla"
    TSLA20200920P1600| 3 -0.9501113 9 29 8 P 1600 2020.09.20 TSLA "Tesla"
    FB20200720C230 | 2 19.1864 31 61 9 C 230 2020.07.20 FB "Facebook"

    ...

    I have been trying to end the capstone but I’m stuck on the test of the last this section, wich gives me the following error:

    quizItem success description error
    -------------------------------------------------------------------------------------------------------------
    exercise5.1 Pass "optProfile Is Defined In Process" ""
    exercise5.1 Pass "optProfile Has Correct Format And Values" ""
    exercise5.2 Pass "edgeProfile Is Defined In Process" ""
    exercise5.2 Pass "edgeProfile Has Correct Format And Values" ""
    exercise5.3 Fail "abort" "abort in before block due to error \"type\""

    This is the meta for the keyed table edgeProfileFull:

    c | t f a
    ---------| -----
    option_id| s
    numTrds | j
    avgEdge | f
    minQty | j
    maxQty | j
    inst_id | j
    opt_type | s
    strike | j
    expiry | d
    inst_syb | s
    inst_name| C


    Thanks!

    • This discussion was modified 5 days, 10 hours ago by  karce.
    karce replied 4 days, 13 hours ago 2 Members · 2 Replies
  • 2 Replies
  • megan_mcp

    Administrator
    September 23, 2024 at 9:39 am

    Hi @karce

    The meta for your table seems correct. However, the first few rows of edgeProfileFull should look as follows (screenshot below).

    I would suggest taking a look back over your edgeProfile table in 5.2 and your join statement in 5.3 to see if you can replicate the output in the screenshot.

    Many thanks,

    Megan

    • karce

      Member
      September 23, 2024 at 4:24 pm

      Everything solved. It was related to the way I loaded the db and the begining.

      Thanks anyway!

Log in to reply.