{"id":1384,"date":"2023-07-26T14:50:54","date_gmt":"2023-07-26T14:50:54","guid":{"rendered":"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/"},"modified":"2023-07-26T14:50:54","modified_gmt":"2023-07-26T14:50:54","slug":"tarih-numarasini-rye-donustur","status":"publish","type":"post","link":"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/","title":{"rendered":"R&#39;de say\u0131lar tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fcl\u00fcr?"},"content":{"rendered":"<p><\/p>\n<hr>\n<p><span style=\"color: #000000;\">\u00c7o\u011fu zaman say\u0131lar\u0131 R&#8217;de tarih bi\u00e7imine d\u00f6n\u00fc\u015ft\u00fcrmeniz gerekebilir. Bunu yapman\u0131n en kolay yolu, R&#8217;de tarihleri i\u015flemek i\u00e7in \u00e7e\u015fitli yararl\u0131 i\u015flevlere sahip olan <a href=\"https:\/\/lubridate.tidyverse.org\/\" target=\"_blank\" rel=\"noopener\">lubridate<\/a> paketini kullanmakt\u0131r.<\/span><\/p>\n<p> <span style=\"color: #000000;\">Bu e\u011fitimde, bu i\u015flevlerin pratikte nas\u0131l kullan\u0131laca\u011f\u0131na ili\u015fkin birka\u00e7 \u00f6rnek verilmektedir.<\/span><\/p>\n<h3> <span style=\"color: #000000;\"><strong>\u00d6rnek 1: Tam Say\u0131lar\u0131 Tarihlere D\u00f6n\u00fc\u015ft\u00fcrme<\/strong><\/span><\/h3>\n<p> <span style=\"color: #000000;\">A\u015fa\u011f\u0131daki kod, bir veri \u00e7er\u00e7evesindeki tamsay\u0131 de\u011ferlerinden olu\u015fan bir s\u00fctunun <strong>, ymd()<\/strong> i\u015flevini kullanarak tarih bi\u00e7imine nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fclece\u011fini g\u00f6sterir:<\/span><\/p>\n<pre style=\"background-color: #ececec; font-size: 15px;\"> <strong><span style=\"color: #107d3f;\"><span style=\"color: #000000;\"><span style=\"color: #993300;\">library<\/span> (lubridate)<\/span>\n<\/span>\n<span style=\"color: #008080;\">#create data frame<\/span>\ndf &lt;- data.frame(date = c(20201022, 20201023, 20201026, 20201027, 20201028),\n                 sales = c(4, 7, 8, 9, 12))\n\n<span style=\"color: #008080;\">#convert date column from numeric to year-month-date format\n<\/span>df$date &lt;- <span style=\"color: #3366ff;\">ymd<\/span> (df$date)\n\n<span style=\"color: #008080;\">#view data frame\n<\/span>df\n\n        dirty date\n1 2020-10-22 4\n2 2020-10-23 7\n3 2020-10-26 8\n4 2020-10-27 9\n5 2020-10-28 12\n\n<span style=\"color: #008080;\">#view class of date column\n<\/span><span style=\"color: #993300;\">class<\/span> (df$date)\n\n[1] \u201cDate\u201d\n<\/strong><\/pre>\n<p> <span style=\"color: #000000;\">Lubridate paketinin farkl\u0131 tarih formatlar\u0131n\u0131 i\u015flemek i\u00e7in \u00e7e\u015fitli i\u015flevlere sahip oldu\u011funu unutmay\u0131n.<\/span><\/p>\n<p> <span style=\"color: #000000;\">\u00d6rne\u011fin, a\u015fa\u011f\u0131da bir veri \u00e7er\u00e7evesindeki tamsay\u0131 de\u011ferlerinden olu\u015fan bir s\u00fctunun <strong>ydm()<\/strong> i\u015flevini kullanarak tarih bi\u00e7imine nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fclece\u011fi g\u00f6sterilmektedir:<\/span><\/p>\n<pre style=\"background-color: #ececec; font-size: 15px;\"> <strong><span style=\"color: #107d3f;\"><span style=\"color: #000000;\"><span style=\"color: #993300;\">library<\/span> (lubridate)<\/span>\n<\/span>\n<span style=\"color: #008080;\">#create data frame<\/span>\ndf &lt;- data.frame(date = c(20202210, 20202310, 20202610, 20202710, 20202810),\n                 sales = c(4, 7, 8, 9, 12))\n\n<span style=\"color: #008080;\">#convert date column from numeric to year-month-date format\n<\/span>df$date &lt;- <span style=\"color: #3366ff;\">ydm<\/span> (df$date)\n\n<span style=\"color: #008080;\">#view data frame\n<\/span>df\n\n        dirty date\n1 2020-10-22 4\n2 2020-10-23 7\n3 2020-10-26 8\n4 2020-10-27 9\n5 2020-10-28 12\n\n<span style=\"color: #008080;\">#view class of date column\n<\/span><span style=\"color: #993300;\">class<\/span> (df$date)\n\n[1] \u201cDate\u201d<\/strong><\/pre>\n<h3> <span style=\"color: #000000;\"><strong>\u00d6rnek 2: Aylar\u0131 ve y\u0131llar\u0131 tarihlere d\u00f6n\u00fc\u015ft\u00fcrme<\/strong><\/span><\/h3>\n<p> <span style=\"color: #000000;\">A\u015fa\u011f\u0131daki kod, 1 Ocak 2010&#8217;dan itibaren ay say\u0131s\u0131n\u0131 temsil eden say\u0131sal de\u011ferlerden olu\u015fan bir s\u00fctunun <strong>, ay()<\/strong> i\u015flevini kullanarak tarih bi\u00e7imine nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fclece\u011fini g\u00f6sterir:<\/span><\/p>\n<pre style=\"background-color: #ececec; font-size: 15px;\"> <strong><span style=\"color: #107d3f;\"><span style=\"color: #000000;\"><span style=\"color: #993300;\">library<\/span> (lubridate)<\/span>\n<\/span>\n<span style=\"color: #008080;\">#create data frame<\/span>\ndf &lt;- data.frame(date = c(11, 15, 18, 22, 24),\n                 sales = c(4, 7, 8, 9, 12))\n\n<span style=\"color: #008080;\">#convert date column from numeric to year-month-date format\n<\/span>df$date &lt;- as. <span style=\"color: #3366ff;\">Date<\/span> (' <span style=\"color: #008000;\">2010-01-01<\/span> ') + <span style=\"color: #3366ff;\">months<\/span> (df$date)\n\n<span style=\"color: #008080;\">#view data frame\n<\/span>df\n\n        dirty date\n1 2010-12-01 4\n2 2011-04-01 7\n3 2011-07-01 8\n4 2011-11-01 9\n5 2012-01-01 12\n\n<span style=\"color: #008080;\">#view class of date column\n<\/span><span style=\"color: #993300;\">class<\/span> (df$date)\n\n[1] \u201cDate\u201d<\/strong><\/pre>\n<p> <span style=\"color: #000000;\">A\u015fa\u011f\u0131daki kod, <strong>Years()<\/strong> i\u015flevini kullanarak 1 Ocak 2010&#8217;dan itibaren y\u0131l say\u0131s\u0131n\u0131 temsil eden say\u0131sal de\u011ferlerden olu\u015fan bir s\u00fctunun tarih bi\u00e7imine nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fclece\u011fini g\u00f6sterir:<\/span><\/p>\n<pre style=\"background-color: #ececec; font-size: 15px;\"> <strong><span style=\"color: #107d3f;\"><span style=\"color: #000000;\"><span style=\"color: #993300;\">library<\/span> (lubridate)<\/span>\n<\/span>\n<span style=\"color: #008080;\">#create data frame<\/span>\ndf &lt;- data.frame(date = c(11, 15, 18, 22, 24),\n                 sales = c(4, 7, 8, 9, 12))\n\n<span style=\"color: #008080;\">#convert date column from numeric to year-month-date format\n<\/span>df$date &lt;- as. <span style=\"color: #3366ff;\">Date<\/span> (' <span style=\"color: #008000;\">2010-01-01<\/span> ') + <span style=\"color: #3366ff;\">years<\/span> (df$date)\n\n<span style=\"color: #008080;\">#view data frame\n<\/span>df\n\n        dirty dates\n1 2021-01-01 4\n2 2025-01-01 7\n3 2028-01-01 8\n4 2032-01-01 9\n5 2034-01-01 12\n\n<span style=\"color: #008080;\">#view class of date column\n<\/span><span style=\"color: #993300;\">class<\/span> (df$date)\n\n[1] \u201cDate\u201d<\/strong><\/pre>\n<p> <span style=\"color: #000000;\"><strong>Bonus:<\/strong> Lubridate paketinde mevcut olan \u00f6zellikleri daha iyi anlamak i\u00e7in <a href=\"https:\/\/rawgit.com\/rstudio\/cheatsheets\/master\/lubridate.pdf\" target=\"_blank\" rel=\"noopener\">bu k\u0131sa notlara<\/a> bak\u0131n.<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u00c7o\u011fu zaman say\u0131lar\u0131 R&#8217;de tarih bi\u00e7imine d\u00f6n\u00fc\u015ft\u00fcrmeniz gerekebilir. Bunu yapman\u0131n en kolay yolu, R&#8217;de tarihleri i\u015flemek i\u00e7in \u00e7e\u015fitli yararl\u0131 i\u015flevlere sahip olan lubridate paketini kullanmakt\u0131r. Bu e\u011fitimde, bu i\u015flevlerin pratikte nas\u0131l kullan\u0131laca\u011f\u0131na ili\u015fkin birka\u00e7 \u00f6rnek verilmektedir. \u00d6rnek 1: Tam Say\u0131lar\u0131 Tarihlere D\u00f6n\u00fc\u015ft\u00fcrme A\u015fa\u011f\u0131daki kod, bir veri \u00e7er\u00e7evesindeki tamsay\u0131 de\u011ferlerinden olu\u015fan bir s\u00fctunun , ymd() i\u015flevini [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[],"class_list":["post-1384","post","type-post","status-publish","format-standard","hentry","category-rehber"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v21.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>R - Statorials&#039;da say\u0131lar tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fcl\u00fcr?<\/title>\n<meta name=\"description\" content=\"Bu e\u011fitimde R&#039;de say\u0131lar\u0131n tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fclece\u011fi birka\u00e7 \u00f6rnekle a\u00e7\u0131klanmaktad\u0131r.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/\" \/>\n<meta property=\"og:locale\" content=\"tr_TR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"R - Statorials&#039;da say\u0131lar tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fcl\u00fcr?\" \/>\n<meta property=\"og:description\" content=\"Bu e\u011fitimde R&#039;de say\u0131lar\u0131n tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fclece\u011fi birka\u00e7 \u00f6rnekle a\u00e7\u0131klanmaktad\u0131r.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/\" \/>\n<meta property=\"og:site_name\" content=\"Statorials\" \/>\n<meta property=\"article:published_time\" content=\"2023-07-26T14:50:54+00:00\" \/>\n<meta name=\"author\" content=\"Dr.benjamin anderson\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Yazan:\" \/>\n\t<meta name=\"twitter:data1\" content=\"Dr.benjamin anderson\" \/>\n\t<meta name=\"twitter:label2\" content=\"Tahmini okuma s\u00fcresi\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 dakika\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/\",\"url\":\"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/\",\"name\":\"R - Statorials&#39;da say\u0131lar tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fcl\u00fcr?\",\"isPartOf\":{\"@id\":\"https:\/\/statorials.org\/tr\/#website\"},\"datePublished\":\"2023-07-26T14:50:54+00:00\",\"dateModified\":\"2023-07-26T14:50:54+00:00\",\"author\":{\"@id\":\"https:\/\/statorials.org\/tr\/#\/schema\/person\/365dc158a39a7c8ae256355451e3de48\"},\"description\":\"Bu e\u011fitimde R&#39;de say\u0131lar\u0131n tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fclece\u011fi birka\u00e7 \u00f6rnekle a\u00e7\u0131klanmaktad\u0131r.\",\"breadcrumb\":{\"@id\":\"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/#breadcrumb\"},\"inLanguage\":\"tr\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Ev\",\"item\":\"https:\/\/statorials.org\/tr\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"R&#39;de say\u0131lar tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fcl\u00fcr?\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/statorials.org\/tr\/#website\",\"url\":\"https:\/\/statorials.org\/tr\/\",\"name\":\"Statorials\",\"description\":\"\u0130statistik okuryazarl\u0131\u011f\u0131 rehberiniz!\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/statorials.org\/tr\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"tr\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/statorials.org\/tr\/#\/schema\/person\/365dc158a39a7c8ae256355451e3de48\",\"name\":\"Dr.benjamin anderson\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"tr\",\"@id\":\"https:\/\/statorials.org\/tr\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/statorials.org\/tr\/wp-content\/uploads\/2023\/10\/Dr.-Benjamin-Anderson-96x96.jpg\",\"contentUrl\":\"https:\/\/statorials.org\/tr\/wp-content\/uploads\/2023\/10\/Dr.-Benjamin-Anderson-96x96.jpg\",\"caption\":\"Dr.benjamin anderson\"},\"description\":\"Merhaba, ben Benjamin, emekli bir istatistik profes\u00f6r\u00fc ve Statorials \u00f6\u011fretmenine d\u00f6n\u00fc\u015ft\u00fcm. \u0130statistik alan\u0131ndaki kapsaml\u0131 deneyimim ve uzmanl\u0131\u011f\u0131mla, \u00f6\u011frencilerimi Statorials arac\u0131l\u0131\u011f\u0131yla g\u00fc\u00e7lendirmek i\u00e7in bilgilerimi payla\u015fmaya can at\u0131yorum. Daha fazlas\u0131n\u0131 bil\",\"sameAs\":[\"https:\/\/statorials.org\/tr\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"R - Statorials&#39;da say\u0131lar tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fcl\u00fcr?","description":"Bu e\u011fitimde R&#39;de say\u0131lar\u0131n tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fclece\u011fi birka\u00e7 \u00f6rnekle a\u00e7\u0131klanmaktad\u0131r.","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:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/","og_locale":"tr_TR","og_type":"article","og_title":"R - Statorials&#39;da say\u0131lar tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fcl\u00fcr?","og_description":"Bu e\u011fitimde R&#39;de say\u0131lar\u0131n tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fclece\u011fi birka\u00e7 \u00f6rnekle a\u00e7\u0131klanmaktad\u0131r.","og_url":"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/","og_site_name":"Statorials","article_published_time":"2023-07-26T14:50:54+00:00","author":"Dr.benjamin anderson","twitter_card":"summary_large_image","twitter_misc":{"Yazan:":"Dr.benjamin anderson","Tahmini okuma s\u00fcresi":"2 dakika"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/","url":"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/","name":"R - Statorials&#39;da say\u0131lar tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fcl\u00fcr?","isPartOf":{"@id":"https:\/\/statorials.org\/tr\/#website"},"datePublished":"2023-07-26T14:50:54+00:00","dateModified":"2023-07-26T14:50:54+00:00","author":{"@id":"https:\/\/statorials.org\/tr\/#\/schema\/person\/365dc158a39a7c8ae256355451e3de48"},"description":"Bu e\u011fitimde R&#39;de say\u0131lar\u0131n tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fclece\u011fi birka\u00e7 \u00f6rnekle a\u00e7\u0131klanmaktad\u0131r.","breadcrumb":{"@id":"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/#breadcrumb"},"inLanguage":"tr","potentialAction":[{"@type":"ReadAction","target":["https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/statorials.org\/tr\/tarih-numarasini-rye-donustur\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Ev","item":"https:\/\/statorials.org\/tr\/"},{"@type":"ListItem","position":2,"name":"R&#39;de say\u0131lar tarihlere nas\u0131l d\u00f6n\u00fc\u015ft\u00fcr\u00fcl\u00fcr?"}]},{"@type":"WebSite","@id":"https:\/\/statorials.org\/tr\/#website","url":"https:\/\/statorials.org\/tr\/","name":"Statorials","description":"\u0130statistik okuryazarl\u0131\u011f\u0131 rehberiniz!","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/statorials.org\/tr\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"tr"},{"@type":"Person","@id":"https:\/\/statorials.org\/tr\/#\/schema\/person\/365dc158a39a7c8ae256355451e3de48","name":"Dr.benjamin anderson","image":{"@type":"ImageObject","inLanguage":"tr","@id":"https:\/\/statorials.org\/tr\/#\/schema\/person\/image\/","url":"https:\/\/statorials.org\/tr\/wp-content\/uploads\/2023\/10\/Dr.-Benjamin-Anderson-96x96.jpg","contentUrl":"https:\/\/statorials.org\/tr\/wp-content\/uploads\/2023\/10\/Dr.-Benjamin-Anderson-96x96.jpg","caption":"Dr.benjamin anderson"},"description":"Merhaba, ben Benjamin, emekli bir istatistik profes\u00f6r\u00fc ve Statorials \u00f6\u011fretmenine d\u00f6n\u00fc\u015ft\u00fcm. \u0130statistik alan\u0131ndaki kapsaml\u0131 deneyimim ve uzmanl\u0131\u011f\u0131mla, \u00f6\u011frencilerimi Statorials arac\u0131l\u0131\u011f\u0131yla g\u00fc\u00e7lendirmek i\u00e7in bilgilerimi payla\u015fmaya can at\u0131yorum. Daha fazlas\u0131n\u0131 bil","sameAs":["https:\/\/statorials.org\/tr"]}]}},"yoast_meta":{"yoast_wpseo_title":"","yoast_wpseo_metadesc":"","yoast_wpseo_canonical":""},"_links":{"self":[{"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/posts\/1384","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/comments?post=1384"}],"version-history":[{"count":0,"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/posts\/1384\/revisions"}],"wp:attachment":[{"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/media?parent=1384"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/categories?post=1384"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/tags?post=1384"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}