{"id":50759,"date":"2021-08-26T00:00:00","date_gmt":"2021-08-26T07:00:00","guid":{"rendered":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/"},"modified":"2025-11-14T07:54:51","modified_gmt":"2025-11-14T15:54:51","slug":"create-interactive-dashboard-with-streamlit-python-and-griddb","status":"publish","type":"post","link":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/","title":{"rendered":"Streamlit\u3001Python\u3001GridDB\u3092\u4f7f\u3063\u3066\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b"},"content":{"rendered":"<h2>\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u6982\u8981<\/h2>\n<h3>\u306f\u3058\u3081\u306b<\/h3>\n<p>\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u306f\u3001GridDB\u3068Streamlit\u3092\u4f7f\u3063\u3066\u3001\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c7\u30fc\u30bf\u30b5\u30a4\u30a8\u30f3\u30b9\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b\u65b9\u6cd5\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002<\/p>\n<p>GridDB\u306b\u53d6\u308a\u8fbc\u307e\u308c\u305f<a href=\"https:\/\/griddb.net\/ja\/blog\/geospatial-analysis-of-nyc-crime-data-with-griddb\/\">\u904e\u53bb\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e<\/a>\u30c7\u30fc\u30bf\u3092\u57fa\u306b\u3001<a href=\"https:\/\/streamlit.io\">Streamlit<\/a>\u3092\u4f7f\u3063\u3066\u30cb\u30e5\u30fc\u30e8\u30fc\u30af\u5e02\u306e\u72af\u7f6a\u306e\u82e6\u60c5\u3092\u8996\u899a\u5316\u3057\u307e\u3059\u3002Streamlit\u3067\u306f\u3001\u5165\u529b\u3084\u51fa\u529b\u306b\u4f7f\u3048\u308b\u69d8\u3005\u306a\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u3092\u4f7f\u3063\u3066\u3001\u3069\u3093\u306a\u7a2e\u985e\u306e\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3067\u3082\u7d20\u65e9\u304f\u7c21\u5358\u306b\u958b\u767a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u306f\u3001\u5165\u529b\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u3092\u4f7f\u3063\u3066GridDB\u306eTQL\u30af\u30a8\u30ea\u6587\u5b57\u5217\u3092\u69cb\u7bc9\u3057\u3001\u30c1\u30e3\u30fc\u30c8\u51fa\u529b\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u3092\u4f7f\u3063\u3066\u8fd4\u3055\u308c\u305f\u30c7\u30fc\u30bf\u3092\u8868\u793a\u3057\u307e\u3059\u3002<\/p>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/08\/streamlit_screenshot.png\"><img fetchpriority=\"high\" decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/08\/streamlit_screenshot.png\" alt=\"\" width=\"1528\" height=\"1526\" class=\"aligncenter size-full wp-image-27728\" srcset=\"\/wp-content\/uploads\/2021\/08\/streamlit_screenshot.png 1528w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot-300x300.png 300w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot-1024x1024.png 1024w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot-150x150.png 150w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot-768x767.png 768w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot-230x230.png 230w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot-400x400.png 400w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot-600x599.png 600w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot-640x640.png 640w\" sizes=\"(max-width: 1528px) 100vw, 1528px\" \/><\/a><\/p>\n<h3>\u8981\u4ef6<\/h3>\n<p>\u4eca\u56de\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u306f\u3001<a href=\"https:\/\/streamlit.io\">Streamlit<\/a>\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3001<a href=\"https:\/\/github.com\/griddb\/python_client\">Python\u30af\u30e9\u30a4\u30a2\u30f3\u30c8<\/a>\u3068\u4e00\u7dd2\u306bGridDB\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u307e\u305f\u3001\u4eca\u56de\u4f7f\u3046\u30cb\u30e5\u30fc\u30e8\u30fc\u30af\u5e02\u306e\u72af\u7f6a\u306b\u95a2\u3059\u308b\u30c7\u30fc\u30bf\u3092DB\u306b\u633f\u5165\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u3053\u308c\u306b\u3064\u3044\u3066\u306f\u3001\u4ee5\u524d\u306e\u30d6\u30ed\u30b0<a href=\"https:\/\/griddb.net\/ja\/blog\/geospatial-analysis-of-nyc-crime-data-with-griddb\/\">GridDB\u3092\u4f7f\u7528\u3057\u305f\u30cb\u30e5\u30fc\u30e8\u30fc\u30af\u306e\u72af\u7f6a\u30c7\u30fc\u30bf\u306e\u5730\u7406\u7a7a\u9593\u5206\u6790<\/a>\u3067\u8a73\u3057\u304f\u7d39\u4ecb\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<h2>\u8a2d\u5b9a<\/h2>\n<h3>GridDB\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b<\/h3>\n<p>GridDB\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u306f\u3001<a href=\"https:\/\/docs.griddb.net\/ja\/gettingstarted\/using-source-code\/\">\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8<\/a>\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<h3>Streamlit\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b<\/h3>\n<p>Installing Streamlit is done via pip<\/p>\n<p><code>pip3 install streamlit --user<\/code><\/p>\n<p><code>Note:<\/code> pip\u3067\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306b\u554f\u984c\u304c\u3042\u308b\u5834\u5408\u306f\u3001pip\u304c\u6700\u65b0\u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u3067\u3042\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<h3>\u30c7\u30fc\u30bf\u3092\u53d6\u308a\u8fbc\u3080<\/h3>\n<p>\u307e\u305a\u6700\u521d\u306b\u3001\u3059\u3079\u3066\u306e\u30c7\u30fc\u30bf\uff08CSV\u5f62\u5f0f\uff09\u3092GridDB\u30b5\u30fc\u30d0\u306b\u8aad\u307f\u8fbc\u307f\u307e\u3059\u3002CSV\u304b\u3089\u30c7\u30fc\u30bf\u30d5\u30ec\u30fc\u30e0\u306b\u76f4\u63a5\u30c7\u30fc\u30bf\u3092\u8aad\u307f\u8fbc\u3080\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u304c\u3001GridDB\u306ehybrid in-memory\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3\u306b\u3088\u308a\u3001\u5148\u306b\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306b\u8aad\u307f\u8fbc\u3080\u3053\u3068\u3067\u3001\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306e\u901f\u5ea6\u304c\u5927\u5e45\u306b\u5411\u4e0a\u3057\u307e\u3059\u3002\u3055\u3089\u306b\u30017m\u884c\u3059\u3079\u3066\u3092\u8aad\u307f\u8fbc\u3080\u306e\u3067\u306f\u306a\u304f\u3001\u95a2\u9023\u3059\u308b\u30c7\u30fc\u30bf\u306e\u307f\u3092\u30c7\u30fc\u30bf\u30d5\u30ec\u30fc\u30e0\u306b\u8aad\u307f\u8fbc\u3080\u305f\u3081\u3001\u30af\u30a8\u30ea\u306e\u30b9\u30d4\u30fc\u30c9\u3082\u5411\u4e0a\u3057\u307e\u3059\u3002<\/p>\n<p>\u305d\u3053\u3067\u3001NYC\u306e\u30c7\u30fc\u30bf\u3092\u81ea\u5206\u306eDB\u306b\u53d6\u308a\u8fbc\u3080\u305f\u3081\u306b\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u4f7f\u3044\u307e\u3059\u3002\u30c7\u30fc\u30bf\u306f<a href=\"https:\/\/data.cityofnewyork.us\/Public-Safety\/NYPD-Complaint-Data-Historic\/qgea-i56i\">NYC Open Data<\/a>\u304b\u3089\u53d6\u5f97\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u30c7\u30fc\u30bf\u3092\u53d6\u308a\u8fbc\u3080\u306b\u306f\u3001 <code>CSVParser<\/code> \u30e9\u30a4\u30d6\u30e9\u30ea\u3092\u4f7f\u3044\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-java\"> Iterable records = CSVFormat.RFC4180.withFirstRecordAsHeader().parse(in);\n   for (CSVRecord record : records) {\n        Complaint c = parseCsvRecord(record);\n        if(c != null)\n            col.put(c);\n   }\n   col.commit();<\/code><\/pre>\n<\/div>\n<p>\u8a73\u3057\u3044\u8aac\u660e\u306b\u3064\u3044\u3066\u306f\u3001\u4ee5\u524d\u306e<a href=\"https:\/\/griddb.net\/ja\/blog\/geospatial-analysis-of-nyc-crime-data-with-griddb\/\">\u3053\u3061\u3089<\/a>\u306e\u30d6\u30ed\u30b0\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u57fa\u672c\u7684\u306a\u6d41\u308c\u3068\u3057\u3066\u306f\u3001<a href=\"https:\/\/griddb.net\/en\/download\/26535\/\">\u3053\u3061\u3089<\/a>\u304b\u3089\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3001\u81ea\u5206\u306e<code>CLASSPATH<\/code>\u306bgriddb.jar\u3068CSV parse jar\u306e\u4e21\u65b9\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002\u305d\u3053\u304b\u3089Ingest.java\u3092\u30b3\u30f3\u30d1\u30a4\u30eb\u3057\u3066\u3001\u540c\u3058\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306b\u3042\u308b<code>rows.csv<\/code>\u3068\u3044\u3046\u540d\u524d\u306e\u30c7\u30fc\u30bf\u3067Java\u30d5\u30a1\u30a4\u30eb\u3092\u5b9f\u884c\u3057\u307e\u3059\u3002\u3059\u308b\u3068\u3001\u30d7\u30ed\u30b0\u30e9\u30e0\u304c\u5b9f\u884c\u3055\u308c\u3001\u30c7\u30fc\u30bf\u304cGridDB\u30b5\u30fc\u30d0\u306b\u53d6\u308a\u8fbc\u307e\u308c\u307e\u3059\u3002<\/p>\n<p>\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u65e9\u304f\u6e08\u307e\u305b\u305f\u3044\u65b9\u306f\u3001700\u4e07\u884c\u3059\u3079\u3066\u304cDB\u306b\u53d6\u308a\u8fbc\u307e\u308c\u308b\u306e\u3092\u5f85\u3064\u5fc5\u8981\u306f\u3042\u308a\u307e\u305b\u3093\u3002\u30c6\u30b9\u30c8\u306e\u305f\u3081\u306b\u306f\u30015\u4e07\u884c\u7a0b\u5ea6\u3092\u53d6\u308a\u8fbc\u3080\u3060\u3051\u3067\u3082\u3088\u3044\u3067\u3057\u3087\u3046\u3002<\/p>\n<p>GridDB\u30b5\u30fc\u30d0\u30fc\u306b\u30c7\u30fc\u30bf\u304c\u5165\u308a\u3001Streamlit\u304c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u305f\u306e\u3067\u3001\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u672c\u984c\u306b\u5165\u308b\u6e96\u5099\u304c\u6574\u3044\u307e\u3057\u305f\u3002<\/p>\n<h2>\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9<\/h2>\n<h3>GridDB\u30b5\u30fc\u30d0\u306b\u63a5\u7d9a\u3059\u308b<\/h3>\n<p>\u307e\u305a\u3001Python\u30b3\u30fc\u30c9\u3092GridDB\u30b5\u30fc\u30d0\u30fc\u306b\u63a5\u7d9a\u3057\u307e\u3059\u3002\u6b21\u306e\u30b9\u30cb\u30da\u30c3\u30c8\u306f\u3001\u4f7f\u7528\u3057\u305f\u30e9\u30a4\u30d6\u30e9\u30ea\u3068\u63a5\u7d9a\u306e\u8a73\u7d30\u3092\u793a\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">#!\/usr\/bin\/python3\nimport pandas as pd\nimport streamlit as st\nimport griddb_python\nimport datetime\nimport traceback\n\ngriddb = griddb_python\nfactory = griddb.StoreFactory.get_instance()\n\ngridstore = factory.get_store(\n    host=\"239.0.0.1\",\n    port=31999,\n    cluster_name=\"defaultCluster\",\n    username=\"admin\",\n    password=\"admin\"\n)<\/code><\/pre>\n<\/div>\n<p>GridDB\u306e\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u63a5\u7d9a\u6587\u5b57\u5217\u3092\u4f7f\u7528\u3057\u3066\u3044\u308b\u3053\u3068\u304c\u308f\u304b\u308a\u307e\u3059\u3002\u307e\u305f\u3001\u512a\u308c\u305f\u30c7\u30fc\u30bf\u30b5\u30a4\u30a8\u30f3\u30b9\u30c4\u30fc\u30eb\u3067\u3042\u308bpandas\u3092\u4f7f\u7528\u3057\u3066\u3044\u307e\u3059\u3002Pandas\u3067\u306eGridDB\u306e\u4f7f\u7528\u306b\u3064\u3044\u3066\u306f\u3053\u3061\u3089\u306e\u30d6\u30ed\u30b0<a href=\"https:\/\/griddb.net\/ja\/blog\/using-pandas-dataframes-with-griddb\/\">GridDB\u4e0a\u3067Pandas\u306e\u30c7\u30fc\u30bf\u30d5\u30ec\u30fc\u30e0\u3092\u4f7f\u7528\u3059\u308b<\/a>\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<h3>\u8907\u6570\u306e\u30b3\u30f3\u30c6\u30ca\u3092\u6271\u3046<\/h3>\n<p>\u6b21\u306b\u3001\u95a2\u9023\u3059\u308b\u30c7\u30fc\u30bf\u3092\u7167\u4f1a\u3057\u307e\u3059\u3002\u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u306f\u8907\u6570\u306e\u30b3\u30f3\u30c6\u30ca\u306b\u4fdd\u5b58\u3055\u308c\u3066\u3044\u308b\u306e\u3067\u3001\u30a2\u30d7\u30ea\u306f1\u3064\u3001\u8907\u6570\u3001\u307e\u305f\u306f\u3059\u3079\u3066\u306e\u30b3\u30f3\u30c6\u30ca\u3092\u7167\u4f1a\u3067\u304d\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u307e\u305a\u6700\u521d\u306b\u3001\u3059\u3079\u3066\u306e\u30b3\u30f3\u30c6\u30ca\u3078\u306e\u30a2\u30af\u30bb\u30b9\u304c\u5fc5\u8981\u306a\u306e\u3067\u3001\u8f9e\u66f8\u3092\u958b\u304d\u3001\u4fdd\u5b58\u3057\u307e\u3059\u3002\u307e\u305f\u3001\u8f9e\u66f8\u306b&#8217;all&#8217;\u30de\u30c3\u30d4\u30f3\u30b0\u3092\u4f5c\u6210\u3057\u3001\u958b\u3044\u305f\u3059\u3079\u3066\u306e\u30b3\u30f3\u30c6\u30ca\u306e\u30ea\u30b9\u30c8\u3092\u683c\u7d0d\u3059\u308b\u3053\u3068\u3067\u3001\u3059\u3079\u3066\u306e\u533a\u9593\u306b\u554f\u3044\u5408\u308f\u305b\u304c\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">cols = {}\nfor x in range(1, 125):\n    col = gridstore.get_container(\"precinct_\"+str(x))\n    if col != None:\n        cols[x] = [col]\n\ncols['all'] = (e[0] for e in cols.values())<\/code><\/pre>\n<\/div>\n<p>\u6700\u5f8c\u306b\u3001Streamlit\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u3067\u9078\u629e\u3055\u308c\u305f\u533a\u9593\u3092\u7e70\u308a\u8fd4\u3057\u691c\u7d22\u3057\u307e\u3059\u3002\u901a\u5e38\u306f1\u3064\u306e\u533a\u9593\u3057\u304b\u3042\u308a\u307e\u305b\u3093\u304c\u3001&#8217;all&#8217;,\u306e\u5834\u5408\u306f\u3059\u3079\u3066\u306e\u533a\u9593\u304c\u7167\u4f1a\u3055\u308c\u307e\u3059\u3002\u7c21\u7565\u5316\u306e\u305f\u3081\u3001<a href=\"\">Multiquery<\/a>\u306f\u4f7f\u7528\u3057\u3066\u3044\u307e\u305b\u3093\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">df=pd.DataFrame()\nfor col in cols[precinct]:\n    try:\n        q = col.query(tql)\n        rs = q.fetch(False)\n        df = df.append(rs.fetch_rows())\n    except:\n        pass\n<\/code><\/pre>\n<\/div>\n<h2>\u5165\u529b\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8<\/h2>\n<p>Streamlit\u306b\u306f\u3001\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u306b\u8ffd\u52a0\u3067\u304d\u308b\u69d8\u3005\u306a\u5165\u529b\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u304c\u3042\u308a\u3001\u305d\u306e\u4e00\u89a7\u306f<a href=\"https:\/\/docs.streamlit.io\/en\/stable\/api.html\">API Reference<\/a>\u306b\u8a18\u8f09\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<h3>\u30ab\u30ec\u30f3\u30c0\u30fc<\/h3>\n<p>streamlit\u306edate_input\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u3067\u306f\u3001\u30e6\u30fc\u30b6\u304c\u958b\u59cb\u65e5\u3068\u7d42\u4e86\u65e5\u3092\u9078\u629e\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u65e5\u4ed8\u306f\u3001<code>datetime.date<\/code>\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30bf\u30d7\u30eb\u3068\u3057\u3066\u8fd4\u3055\u308c\u307e\u3059\u304c\u3001\u3053\u308c\u306f\u307e\u305a\u3001<code>datetime.datetime.combine()<\/code>\u3092\u4f7f\u3063\u3066<code>datetime.datetime<\/code>\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306b\u5909\u63db\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">date_range = st.date_input(\"Period\", [datetime.date(2010, 1,1), datetime.date(2020, 12, 31) ])\nstart = datetime.datetime.combine(date_range[0], datetime.datetime.min.time())\nend = datetime.datetime.combine(date_range[1], datetime.datetime.min.time())<\/code><\/pre>\n<\/div>\n<p>\u305d\u306e\u5f8c\u3001<code>datetime.datetime<\/code>\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092<code>int(datetime.datetime.timestamp()\u00ac*1000)<\/code>\u3067\u30df\u30ea\u79d2\u5358\u4f4d\u306e\u30a8\u30dd\u30c3\u30af\u306b\u5909\u63db\u3057\u3001TQL\u30af\u30a8\u30ea\u3067\u4f7f\u7528\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">tql = \"select * where CMPLNT_FR > TO_TIMESTAMP_MS(\"+str(int(start.timestamp()*1000))+\") AND CMPLNT_FR &lt; TO_TIMESTAMP_MS(\"+str(int(end.timestamp()*1000))+\")\"<\/code><\/pre>\n<\/div>\n<h3>\u30b9\u30e9\u30a4\u30c0\u30fc\u3001\u30e9\u30b8\u30aa\u30dc\u30bf\u30f3\u3001\u30bb\u30ec\u30af\u30c8\u30dc\u30c3\u30af\u30b9<\/h3>\n<p>Streamlit\u306e\u4ed6\u306e\u5165\u529b\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u306f\u975e\u5e38\u306b\u30b7\u30f3\u30d7\u30eb\u3067\u3001\u305d\u308c\u305e\u308c\u304c\u5165\u529b\u5019\u88dc\u306e\u30ea\u30b9\u30c8\u3092\u53d7\u3051\u53d6\u308a\u3001\u9078\u629e\u3055\u308c\u305f\u9805\u76ee\u3092\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">precinct = st.select_slider(\"Precinct\", list(cols.keys()), value='all' )\nbr_name = st.selectbox(\"Borough\", [\"ALL\", \"MANHATTAN\", \"QUEENS\", \"BRONX\" , \"BROOKLYN\", \"STATEN ISLAND\" ])\nctype = st.radio(\"Type\", [\"ALL\", \"VIOLATION\", \"MISDEMEANOR\" , \"FELONY\" ])<\/code><\/pre>\n<\/div>\n<p>\u3053\u308c\u3089\u306e\u51fa\u529b\u306f\u3001TQL\u6587\u3067\u4f7f\u7528\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">if br_name != \"ALL\":\n    tql = tql + \" AND BORO_NM = '\"+br_name+\"'\"\n\nif ctype != \"ALL\":\n    tql = tql + \" AND LAW_CAT_CD = '\"+ctype+\"'\"<\/code><\/pre>\n<\/div>\n<h2>\u51fa\u529b\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8<\/h2>\n<p>\u4eca\u56de\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u4f7f\u7528\u3059\u308b\u68d2\u30b0\u30e9\u30d5\u3001\u30c6\u30ad\u30b9\u30c8\u3001\u5730\u56f3\u306a\u3069\u3001\u3044\u304f\u3064\u304b\u306e\u7570\u306a\u308b\u51fa\u529b\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u304c\u7528\u610f\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<h3>\u30bf\u30a4\u30c8\u30eb\u3068\u30c6\u30ad\u30b9\u30c8<\/h3>\n<p>\u30c7\u30fc\u30bf\u3092\u8868\u793a\u3059\u308b\u524d\u306b\u3001\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u5168\u4f53\u306e\u4e00\u4f53\u611f\u3092\u51fa\u3059\u305f\u3081\u306b\u3001\u30bf\u30a4\u30c8\u30eb\u3084\u88dc\u52a9\u30c6\u30ad\u30b9\u30c8\u3092\u8868\u793a\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002\u4f8b\u3048\u3070\u3001<code>st.title<\/code>\u3092\u4f7f\u3063\u3066\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u306e\u30bf\u30a4\u30c8\u30eb\u3092\u8868\u793a\u3059\u3057\u305f\u308a\u3001<code>st.write<\/code>\u3092\u4f7f\u3063\u3066\u30c6\u30ad\u30b9\u30c8\u3092\u8868\u793a\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u3053\u3053\u3067\u306f\u3001\u3059\u3079\u3066\u306e\u5165\u529b\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u306e\u524d\u306b\u3001\u30bf\u30a4\u30c8\u30eb\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n<p><code>st.title('NYC Crime Complaint Data')<\/code><\/p>\n<p>\u3053\u306e\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306e\u76ee\u7684\u3092\u7c21\u5358\u306b\u8aac\u660e\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p><code>st.write<\/code>\u3000\uff08\u8868\u793a\u3055\u305b\u305f\u3044\u72af\u7f6a\u30c7\u30fc\u30bf\u306e\u60c5\u5831\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u5b8c\u4e86\u3059\u308b\u3068\u3001\u4e0b\u90e8\u306b\u68d2\u30b0\u30e9\u30d5\u304c\u8868\u793a\u3055\u308c\u307e\u3059\u3002\uff09<\/p>\n<h3>\u5730\u56f3<\/h3>\n<p>\u30c7\u30fc\u30bf\u306e\u5730\u56f3\u3092\u8868\u793a\u3059\u308b\u306b\u306f\u3001<a href=\"https:\/\/docs.streamlit.io\/en\/stable\/api.html?highlight=pydeck\">pydeck<\/a>\u306e\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">if precinct != \"all\":\n    df = df.rename(columns={'Latitude': 'lat', 'Longitude': 'lon'})\n    st.pydeck_chart(pdk.Deck(\n         map_style='mapbox:\/\/styles\/mapbox\/light-v9',\n         initial_view_state=pdk.ViewState(\n             latitude=40.76,\n             longitude=-73.93,\n             zoom=10,\n             pitch=50,\n         ),\n         layers=[\n             pdk.Layer(\n                'HexagonLayer',\n                data=df,\n                get_position='[lon, lat]',\n                radius=100,\n                get_elevation=500,\n                elevation_scale=4,\n                elevation_range=[0, 1000],\n                pickable=True,\n                extruded=True,\n             ),\n             pdk.Layer(\n                 'ScatterplotLayer',\n                 data=df,\n                 get_position='[lon, lat]',\n                 get_color='[200, 30, 0, 160]',\n                 get_radius=100,\n             ),\n         ],\n    ))\nelse:\n    print(\"Can only draw maps for single precincts\")<\/code><\/pre>\n<\/div>\n<p>\u307e\u305a\u59cb\u3081\u306b\u3001\u30ec\u30f3\u30c0\u30ea\u30f3\u30b0\u3059\u308b\u30c7\u30fc\u30bf\u3092\u3001\u300c\u5168\u533a\u9593\u300d\u3088\u308a\u3082\u5c0f\u3055\u3044\u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u306e\u307f\u306b\u9650\u5b9a\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u3059\u3079\u3066\u306e\u30c7\u30fc\u30bf\u30dd\u30a4\u30f3\u30c8\u3092\u63cf\u753b\u3057\u3088\u3046\u3068\u3059\u308b\u3068\u3001\u30b9\u30af\u30ea\u30d7\u30c8\u5168\u4f53\u306b\u8ca0\u62c5\u304c\u304b\u304b\u308b\u305f\u3081\u3067\u3059\u3002\u305d\u306e\u5f8c\u306f\u3001\u3059\u3067\u306b\u8a2d\u5b9a\u3057\u3066\u3042\u308b\u30c7\u30fc\u30bf\u30d5\u30ec\u30fc\u30e0\u3084\u305d\u306e\u4ed6\u306e\u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u5165\u529b\u3057\u307e\u3059\u3002<\/p>\n<p>\u3053\u308c\u3067\u3001\u7279\u5b9a\u306e\u533a\u9593\u3092\u9078\u629e\u3059\u308b\u3068\u3001\u304d\u308c\u3044\u306a\u5730\u56f3\u304c\u8868\u793a\u3055\u308c\u308b\u306f\u305a\u3067\u3059\u3002<\/p>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/08\/pydeck.png\"><img decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/08\/pydeck.png\" alt=\"\" width=\"710\" height=\"504\" class=\"aligncenter size-full wp-image-27729\" srcset=\"\/wp-content\/uploads\/2021\/08\/pydeck.png 710w, \/wp-content\/uploads\/2021\/08\/pydeck-300x213.png 300w, \/wp-content\/uploads\/2021\/08\/pydeck-600x426.png 600w\" sizes=\"(max-width: 710px) 100vw, 710px\" \/><\/a><\/p>\n<h3>\u68d2\u30b0\u30e9\u30d5<\/h3>\n<p><code>bucket_size<\/code>\u306e\u6642\u9593\u306b\u304a\u3051\u308b\u72af\u7f6a\u306e\u82e6\u60c5\u306e\u4ef6\u6570\u3092\u52b9\u679c\u7684\u306b\u8868\u793a\u3059\u308b\u305f\u3081\u306b\u306f\u3001\u30c7\u30fc\u30bf\u3092\u30d0\u30b1\u30c3\u30c8\u5316\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u305d\u306e\u524d\u306b\u3001\u307e\u305a\u4f7f\u7528\u3059\u308b\u30d0\u30b1\u30c3\u30c8\u306e\u6570\u3092\u6c7a\u5b9a\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u304c\u3001\u3053\u308c\u306f\u6642\u9593 <code>bucket_size<\/code> \u306b\u4f9d\u5b58\u3057\u307e\u3059\u3002\u3082\u3057<code>bucket_size<\/code>\u304c\u6570\u9031\u9593\u3067\u3042\u308c\u3070\u3001\u6708\u5358\u4f4d\u306e\u30d0\u30b1\u30c3\u30c8\u3092\u4f7f\u3046\u306e\u306f\u610f\u5473\u304c\u3042\u308a\u307e\u305b\u3093\u3057\u3001\u305d\u306e\u9006\u3082\u3057\u304b\u308a\u3067\u3059\u3002\u307e\u305f\u3001<code>bucket_size<\/code>\u304c\u6570\u5e74\u3067\u3042\u308c\u3070\u3001\u65e5\u5358\u4f4d\u3084\u9031\u5358\u4f4d\u306e\u30d0\u30b1\u30c3\u30c8\u3092\u4f7f\u3063\u3066\u3082\u30c7\u30fc\u30bf\u3092\u3046\u307e\u304f\u8996\u899a\u5316\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u305b\u3093\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">bucket_size='Y'\nif delta.days &lt; 800:\n    bucket_size = 'M'\nelif delta.days &lt; 90:\n    bucket_size = 'D'\n<\/code><\/pre>\n<\/div>\n<p>\u3053\u308c\u3067\u3001<code>CMPLNT_FR<\/code>\u5217\u3092<code>Pandas Datetime<\/code>\u306b\u5909\u63db\u3057\u3066\u3001\u30c7\u30fc\u30bf\u3092\u30d0\u30b1\u30c3\u30c8\u3084\u30b0\u30eb\u30fc\u30d7\u306b\u5165\u308c\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">df['CMPLNT_FR'] = pd.to_datetime(df['CMPLNT_FR'])\ndf = df.groupby([pd.Grouper(key='CMPLNT_FR',freq=bucket_size)]).size().reset_index(name='count')<\/code><\/pre>\n<\/div>\n<p>\u68d2\u30b0\u30e9\u30d5\u306e\u8868\u793a\u306f\u3001\u30b7\u30f3\u30d7\u30eb\u306a\u30ef\u30f3\u30e9\u30a4\u30ca\u30fc\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">st.bar_chart(data=df)<\/code><\/pre>\n<\/div>\n<h3>\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u5b9f\u884c\u3059\u308b<\/h3>\n<p>\u3059\u3079\u3066\u306e\u8a2d\u5b9a\u304c\u5b8c\u4e86\u3057\u305f\u3089\u3001\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u5b9f\u884c\u3057\u307e\u3059\u3002<\/p>\n<p><code>streamlit run app.py<\/code><\/p>\n<p>\u305d\u3057\u3066\u3001\u8868\u793a\u3055\u308c\u305f\u5916\u90e8URL\u306b\u5f93\u3046\u3068\u3001\u304d\u308c\u3044\u306a\u30c7\u30fc\u30bf\u30b5\u30a4\u30a8\u30f3\u30b9\u30fb\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u30d6\u30e9\u30a6\u30b6\u3067\u898b\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<h2>\u307e\u3068\u3081<\/h2>\n<p>\u4f5c\u6210\u3055\u308c\u308b\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u306e\u54c1\u8cea\u3068\u5fc5\u8981\u306a\u30b3\u30fc\u30c9\u91cf\u3092\u8003\u616e\u3059\u308b\u3068\u3001Streamlit\u306f\u30c7\u30fc\u30bf\u30c9\u30ea\u30d6\u30f3\u306a\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4fe1\u3058\u3089\u308c\u306a\u3044\u307b\u3069\u8fc5\u901f\u304b\u3064\u7c21\u5358\u306b\u958b\u767a\u3067\u304d\u308b\u3053\u3068\u3092\u793a\u3057\u307e\u3057\u305f\u3002GridDB\u306e\u9ad8\u3044\u30d1\u30d5\u30a9\u30fc\u30de\u30f3\u30b9\u3068\u30b9\u30b1\u30fc\u30e9\u30d3\u30ea\u30c6\u30a3\u3092\u7d44\u307f\u5408\u308f\u305b\u308b\u3053\u3068\u3067\u3001\u958b\u767a\u62c5\u5f53\u8005\u306f\u591a\u984d\u306e\u6295\u8cc7\u3084\u6642\u9593\u3092\u304b\u3051\u305a\u306b\u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u3092\u8996\u899a\u5316\u3057\u3001\u6d1e\u5bdf\u3092\u5f97\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u4eca\u56de\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u4f7f\u7528\u3057\u305f\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u306f\u3001GridDB.net\u306eGitHub\u30a2\u30ab\u30a6\u30f3\u30c8<a href=\"https:\/\/github.com\/griddbnet\/Blogs\/tree\/main\/Create%20Interactive%20Dashboard%20with%20Streamlit%2C%20Python%20and%20GridDB\">\u3053\u3061\u3089<\/a>\u306b\u63b2\u8f09\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u6700\u5f8c\u306b\u3001\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u5168\u4f53\u306e\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8\u306f\u3053\u306e\u3088\u3046\u306b\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/08\/streamlit_screenshot_with_pydeck.png\"><img decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/08\/streamlit_screenshot_with_pydeck.png\" alt=\"\" width=\"774\" height=\"1543\" class=\"aligncenter size-full wp-image-27725\" srcset=\"\/wp-content\/uploads\/2021\/08\/streamlit_screenshot_with_pydeck.png 774w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot_with_pydeck-150x300.png 150w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot_with_pydeck-514x1024.png 514w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot_with_pydeck-768x1531.png 768w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot_with_pydeck-770x1536.png 770w, \/wp-content\/uploads\/2021\/08\/streamlit_screenshot_with_pydeck-501x999.png 501w\" sizes=\"(max-width: 774px) 100vw, 774px\" \/><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u6982\u8981 \u306f\u3058\u3081\u306b \u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u306f\u3001GridDB\u3068Streamlit\u3092\u4f7f\u3063\u3066\u3001\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c7\u30fc\u30bf\u30b5\u30a4\u30a8\u30f3\u30b9\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b\u65b9\u6cd5\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002 GridDB\u306b\u53d6\u308a\u8fbc\u307e\u308c\u305f\u904e\u53bb\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u30c7 [&hellip;]<\/p>\n","protected":false},"author":71,"featured_media":50240,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1005],"tags":[],"class_list":["post-50759","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-1005"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Streamlit\u3001Python\u3001GridDB\u3092\u4f7f\u3063\u3066\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b | GridDB: Open Source Time Series Database for IoT<\/title>\n<meta name=\"description\" content=\"\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u6982\u8981 \u306f\u3058\u3081\u306b\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/griddb.net\/ja\/\u672a\u5206\u985e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/\" \/>\n<meta property=\"og:locale\" content=\"ja_JP\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Streamlit\u3001Python\u3001GridDB\u3092\u4f7f\u3063\u3066\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b | GridDB: Open Source Time Series Database for IoT\" \/>\n<meta property=\"og:description\" content=\"\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u6982\u8981 \u306f\u3058\u3081\u306b\" \/>\n<meta property=\"og:url\" content=\"https:\/\/griddb.net\/ja\/\u672a\u5206\u985e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/\" \/>\n<meta property=\"og:site_name\" content=\"GridDB: Open Source Time Series Database for IoT\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/griddbcommunity\/\" \/>\n<meta property=\"article:published_time\" content=\"2021-08-26T07:00:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-11-14T15:54:51+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/streamlit1.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1160\" \/>\n\t<meta property=\"og:image:height\" content=\"653\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Owen\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@GridDBCommunity\" \/>\n<meta name=\"twitter:site\" content=\"@GridDBCommunity\" \/>\n<meta name=\"twitter:label1\" content=\"\u57f7\u7b46\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"Owen\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593\" \/>\n\t<meta name=\"twitter:data2\" content=\"2\u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/\"},\"author\":{\"name\":\"Owen\",\"@id\":\"https:\/\/griddb.net\/en\/#\/schema\/person\/0f2f6d4b593adde8c43cf3ea5c794c66\"},\"headline\":\"Streamlit\u3001Python\u3001GridDB\u3092\u4f7f\u3063\u3066\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b\",\"datePublished\":\"2021-08-26T07:00:00+00:00\",\"dateModified\":\"2025-11-14T15:54:51+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/\"},\"wordCount\":79,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/griddb.net\/en\/#organization\"},\"image\":{\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#primaryimage\"},\"thumbnailUrl\":\"\/wp-content\/uploads\/2021\/09\/streamlit1.png\",\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/\",\"url\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/\",\"name\":\"Streamlit\u3001Python\u3001GridDB\u3092\u4f7f\u3063\u3066\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b | GridDB: Open Source Time Series Database for IoT\",\"isPartOf\":{\"@id\":\"https:\/\/griddb.net\/en\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#primaryimage\"},\"thumbnailUrl\":\"\/wp-content\/uploads\/2021\/09\/streamlit1.png\",\"datePublished\":\"2021-08-26T07:00:00+00:00\",\"dateModified\":\"2025-11-14T15:54:51+00:00\",\"description\":\"\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u6982\u8981 \u306f\u3058\u3081\u306b\",\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#primaryimage\",\"url\":\"\/wp-content\/uploads\/2021\/09\/streamlit1.png\",\"contentUrl\":\"\/wp-content\/uploads\/2021\/09\/streamlit1.png\",\"width\":1160,\"height\":653},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/griddb.net\/en\/#website\",\"url\":\"https:\/\/griddb.net\/en\/\",\"name\":\"GridDB: Open Source Time Series Database for IoT\",\"description\":\"GridDB is an open source time-series database with the performance of NoSQL and convenience of SQL\",\"publisher\":{\"@id\":\"https:\/\/griddb.net\/en\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/griddb.net\/en\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"ja\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/griddb.net\/en\/#organization\",\"name\":\"Fixstars\",\"url\":\"https:\/\/griddb.net\/en\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/griddb.net\/en\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png\",\"contentUrl\":\"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png\",\"width\":200,\"height\":83,\"caption\":\"Fixstars\"},\"image\":{\"@id\":\"https:\/\/griddb.net\/en\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/griddbcommunity\/\",\"https:\/\/x.com\/GridDBCommunity\",\"https:\/\/www.linkedin.com\/company\/griddb-by-toshiba\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/griddb.net\/en\/#\/schema\/person\/0f2f6d4b593adde8c43cf3ea5c794c66\",\"name\":\"Owen\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/griddb.net\/en\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/47438a5c81215c7a9043be1b427e0bbd8dc0f77bd536f147f8495575149e4325?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/47438a5c81215c7a9043be1b427e0bbd8dc0f77bd536f147f8495575149e4325?s=96&d=mm&r=g\",\"caption\":\"Owen\"},\"url\":\"https:\/\/griddb.net\/ja\/author\/owen\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Streamlit\u3001Python\u3001GridDB\u3092\u4f7f\u3063\u3066\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b | GridDB: Open Source Time Series Database for IoT","description":"\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u6982\u8981 \u306f\u3058\u3081\u306b","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/griddb.net\/ja\/\u672a\u5206\u985e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/","og_locale":"ja_JP","og_type":"article","og_title":"Streamlit\u3001Python\u3001GridDB\u3092\u4f7f\u3063\u3066\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b | GridDB: Open Source Time Series Database for IoT","og_description":"\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u6982\u8981 \u306f\u3058\u3081\u306b","og_url":"https:\/\/griddb.net\/ja\/\u672a\u5206\u985e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/","og_site_name":"GridDB: Open Source Time Series Database for IoT","article_publisher":"https:\/\/www.facebook.com\/griddbcommunity\/","article_published_time":"2021-08-26T07:00:00+00:00","article_modified_time":"2025-11-14T15:54:51+00:00","og_image":[{"width":1160,"height":653,"url":"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/streamlit1.png","type":"image\/png"}],"author":"Owen","twitter_card":"summary_large_image","twitter_creator":"@GridDBCommunity","twitter_site":"@GridDBCommunity","twitter_misc":{"\u57f7\u7b46\u8005":"Owen","\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593":"2\u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#article","isPartOf":{"@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/"},"author":{"name":"Owen","@id":"https:\/\/griddb.net\/en\/#\/schema\/person\/0f2f6d4b593adde8c43cf3ea5c794c66"},"headline":"Streamlit\u3001Python\u3001GridDB\u3092\u4f7f\u3063\u3066\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b","datePublished":"2021-08-26T07:00:00+00:00","dateModified":"2025-11-14T15:54:51+00:00","mainEntityOfPage":{"@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/"},"wordCount":79,"commentCount":0,"publisher":{"@id":"https:\/\/griddb.net\/en\/#organization"},"image":{"@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#primaryimage"},"thumbnailUrl":"\/wp-content\/uploads\/2021\/09\/streamlit1.png","inLanguage":"ja","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/","url":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/","name":"Streamlit\u3001Python\u3001GridDB\u3092\u4f7f\u3063\u3066\u30a4\u30f3\u30bf\u30e9\u30af\u30c6\u30a3\u30d6\u306a\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u3092\u4f5c\u6210\u3059\u308b | GridDB: Open Source Time Series Database for IoT","isPartOf":{"@id":"https:\/\/griddb.net\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#primaryimage"},"image":{"@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#primaryimage"},"thumbnailUrl":"\/wp-content\/uploads\/2021\/09\/streamlit1.png","datePublished":"2021-08-26T07:00:00+00:00","dateModified":"2025-11-14T15:54:51+00:00","description":"\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u6982\u8981 \u306f\u3058\u3081\u306b","inLanguage":"ja","potentialAction":[{"@type":"ReadAction","target":["https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/"]}]},{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/create-interactive-dashboard-with-streamlit-python-and-griddb\/#primaryimage","url":"\/wp-content\/uploads\/2021\/09\/streamlit1.png","contentUrl":"\/wp-content\/uploads\/2021\/09\/streamlit1.png","width":1160,"height":653},{"@type":"WebSite","@id":"https:\/\/griddb.net\/en\/#website","url":"https:\/\/griddb.net\/en\/","name":"GridDB: Open Source Time Series Database for IoT","description":"GridDB is an open source time-series database with the performance of NoSQL and convenience of SQL","publisher":{"@id":"https:\/\/griddb.net\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/griddb.net\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"ja"},{"@type":"Organization","@id":"https:\/\/griddb.net\/en\/#organization","name":"Fixstars","url":"https:\/\/griddb.net\/en\/","logo":{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/griddb.net\/en\/#\/schema\/logo\/image\/","url":"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png","contentUrl":"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png","width":200,"height":83,"caption":"Fixstars"},"image":{"@id":"https:\/\/griddb.net\/en\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/griddbcommunity\/","https:\/\/x.com\/GridDBCommunity","https:\/\/www.linkedin.com\/company\/griddb-by-toshiba"]},{"@type":"Person","@id":"https:\/\/griddb.net\/en\/#\/schema\/person\/0f2f6d4b593adde8c43cf3ea5c794c66","name":"Owen","image":{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/griddb.net\/en\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/47438a5c81215c7a9043be1b427e0bbd8dc0f77bd536f147f8495575149e4325?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/47438a5c81215c7a9043be1b427e0bbd8dc0f77bd536f147f8495575149e4325?s=96&d=mm&r=g","caption":"Owen"},"url":"https:\/\/griddb.net\/ja\/author\/owen\/"}]}},"_links":{"self":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts\/50759","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/users\/71"}],"replies":[{"embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/comments?post=50759"}],"version-history":[{"count":1,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts\/50759\/revisions"}],"predecessor-version":[{"id":51595,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts\/50759\/revisions\/51595"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/media\/50240"}],"wp:attachment":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/media?parent=50759"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/categories?post=50759"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/tags?post=50759"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}