{
  "id": 306870,
  "title": "Is price is the price of an article or the customer has spend amount on that article??  ",
  "url": "/competitions/h-and-m-personalized-fashion-recommendations/discussion/306870",
  "author_name": "",
  "post_date": "2022-02-11T09:22:02.894697200Z",
  "votes": 2,
  "comment_count": 2,
  "views": 0,
  "content": "<p>Please clarify this. In the transaction table what does price means? End of the day analysis won't change much but will have scope to leverage the article data with price value. </p>",
  "messages": [
    {
      "id": "1685442",
      "postDate": "02/11/2022 09:22:02",
      "content": "<p>Please clarify this. In the transaction table what does price means? End of the day analysis won't change much but will have scope to leverage the article data with price value. </p>",
      "rawMarkdown": "Please clarify this. In the transaction table what does price means? End of the day analysis won't change much but will have scope to leverage the article data with price value.",
      "votes": null
    },
    {
      "id": "1685784",
      "postDate": "02/11/2022 14:37:05",
      "content": "<p>It's in the transaction data, not the article data, so it seems clear that it's what the customer paid.</p>\n<p>And it's easy to see there are multiple prices for the same article, even on the same day/channel.</p>\n<p>Here's how you find them:</p>\n<pre><code>grouped_df = transactions_df.groupby([\"sales_channel_id\", \"article_id\", \"t_dat\"])\ngrouped_df[\"price\"].nunique().sort_values(ascending=False)\n</code></pre>\n<p>And here's an example:<br>\n<code>transactions_df.query(\"article_id==706016001 &amp; t_dat=='2019-11-29' &amp; sales_channel_id==2\")</code></p>\n<p>Of course, it's still possible that price is set at the channel/store/date level, and doesn't include individual customer discounts (i.e. coupons) but it's not likely.</p>",
      "rawMarkdown": "It's in the transaction data, not the article data, so it seems clear that it's what the customer paid.\n\nAnd it's easy to see there are multiple prices for the same article, even on the same day/channel.\n\nHere's how you find them:\n```\ngrouped_df = transactions_df.groupby([\"sales_channel_id\", \"article_id\", \"t_dat\"])\ngrouped_df[\"price\"].nunique().sort_values(ascending=False)\n```\n\nAnd here's an example:\n`transactions_df.query(\"article_id==706016001 & t_dat=='2019-11-29' & sales_channel_id==2\")`\n\nOf course, it's still possible that price is set at the channel/store/date level, and doesn't include individual customer discounts (i.e. coupons) but it's not likely.",
      "votes": null
    },
    {
      "id": "1686014",
      "postDate": "02/11/2022 17:34:34",
      "content": "<p>Thank you for the explanation.</p>",
      "rawMarkdown": "Thank you for the explanation.",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 1685784,
      "author_name": "jacob34",
      "author_url": "",
      "post_date": "02/11/2022 14:37:05",
      "content": "<p>It's in the transaction data, not the article data, so it seems clear that it's what the customer paid.</p>\n<p>And it's easy to see there are multiple prices for the same article, even on the same day/channel.</p>\n<p>Here's how you find them:</p>\n<pre><code>grouped_df = transactions_df.groupby([\"sales_channel_id\", \"article_id\", \"t_dat\"])\ngrouped_df[\"price\"].nunique().sort_values(ascending=False)\n</code></pre>\n<p>And here's an example:<br>\n<code>transactions_df.query(\"article_id==706016001 &amp; t_dat=='2019-11-29' &amp; sales_channel_id==2\")</code></p>\n<p>Of course, it's still possible that price is set at the channel/store/date level, and doesn't include individual customer discounts (i.e. coupons) but it's not likely.</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 1686014,
      "author_name": "pankajkumar",
      "author_url": "",
      "post_date": "02/11/2022 17:34:34",
      "content": "<p>Thank you for the explanation.</p>",
      "votes": null,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "1685442": "Please clarify this. In the transaction table what does price means? End of the day analysis won't change much but will have scope to leverage the article data with price value.",
    "1685784": "It's in the transaction data, not the article data, so it seems clear that it's what the customer paid.\n\nAnd it's easy to see there are multiple prices for the same article, even on the same day/channel.\n\nHere's how you find them:\n```\ngrouped_df = transactions_df.groupby([\"sales_channel_id\", \"article_id\", \"t_dat\"])\ngrouped_df[\"price\"].nunique().sort_values(ascending=False)\n```\n\nAnd here's an example:\n`transactions_df.query(\"article_id==706016001 & t_dat=='2019-11-29' & sales_channel_id==2\")`\n\nOf course, it's still possible that price is set at the channel/store/date level, and doesn't include individual customer discounts (i.e. coupons) but it's not likely.",
    "1686014": "Thank you for the explanation."
  },
  "source": "meta"
}