{"id":3680,"date":"2023-07-16T04:16:30","date_gmt":"2023-07-16T04:16:30","guid":{"rendered":"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/"},"modified":"2023-07-16T04:16:30","modified_gmt":"2023-07-16T04:16:30","slug":"rdeki-satirlari-cogalt","status":"publish","type":"post","link":"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/","title":{"rendered":"R&#39;de bir veri \u00e7er\u00e7evesindeki sat\u0131rlar nas\u0131l \u00e7o\u011falt\u0131l\u0131r"},"content":{"rendered":"<p><\/p>\n<hr>\n<p><span style=\"color: #000000;\"><a href=\"https:\/\/dplyr.tidyverse.org\/\" target=\"_blank\" rel=\"noopener\">Dplyr<\/a> paketindeki i\u015flevleri kullanarak R&#8217;deki bir veri \u00e7er\u00e7evesindeki sat\u0131rlar\u0131 \u00e7o\u011faltmak i\u00e7in a\u015fa\u011f\u0131daki y\u00f6ntemleri kullanabilirsiniz:<\/span><\/p>\n<p> <span style=\"color: #000000;\"><strong>Y\u00f6ntem 1: Her sat\u0131r\u0131 ayn\u0131 say\u0131da \u00e7o\u011falt\u0131n<\/strong><\/span><\/p>\n<pre style=\"background-color: #ececec; font-size: 15px;\"> <strong><span style=\"color: #008000;\">library<\/span> (dplyr)\n\n<span style=\"color: #008080;\">#replicate each row 3 times<\/span>\ndf %&gt;% slice(rep(1:n(), <span style=\"color: #3366ff;\">each<\/span> <span style=\"color: #000000;\">= 3))<\/span><\/strong><\/pre>\n<p> <span style=\"color: #000000;\"><strong>Y\u00f6ntem 2: Her sat\u0131r\u0131 farkl\u0131 say\u0131da \u00e7o\u011falt\u0131n<\/strong><\/span><\/p>\n<pre style=\"background-color: #ececec; font-size: 15px;\"> <strong><span style=\"color: #008000;\">library<\/span> (dplyr)\n\n<span style=\"color: #008080;\">#replicate the first row 3 times and the second row 5 times<\/span>\n<span style=\"color: #000000;\">df %&gt;% slice(rep(1:n(), <span style=\"color: #3366ff;\">times<\/span> = c(3, 5)))<\/span><\/strong><\/pre>\n<p> <span style=\"color: #000000;\">A\u015fa\u011f\u0131daki \u00f6rnekler her y\u00f6ntemin pratikte nas\u0131l kullan\u0131laca\u011f\u0131n\u0131 g\u00f6stermektedir.<\/span><\/p>\n<h2> <span style=\"color: #000000;\"><strong>\u00d6rnek 1: Her sat\u0131r\u0131 ayn\u0131 say\u0131da \u00e7o\u011falt\u0131n<\/strong><\/span><\/h2>\n<p> <span style=\"color: #000000;\">R&#8217;de iki sat\u0131rl\u0131 a\u015fa\u011f\u0131daki veri \u00e7er\u00e7evesine sahip oldu\u011fumuzu varsayal\u0131m:<\/span><\/p>\n<pre style=\"background-color: #ececec; font-size: 15px;\"> <span style=\"color: #000000;\"><strong><span style=\"color: #008080;\">#create data frame\n<span style=\"color: #000000;\">df &lt;- data. <span style=\"color: #3366ff;\">frame<\/span> (team=c('A', 'B'),\n                 dots=c(10, 15),\n                 rebounds=c(4, 8),\n                 assists=c(2, 5))\n\n<span style=\"color: #008080;\">#view data frame\n<\/span>df\n\n  team points rebound assists\n1 to 10 4 2\n2 B 15 8 5\n<\/span><\/span><\/strong><\/span><\/pre>\n<p> <span style=\"color: #000000;\">Veri \u00e7er\u00e7evesinin her sat\u0131r\u0131n\u0131 \u00fc\u00e7 kez tekrarlamak i\u00e7in a\u015fa\u011f\u0131daki s\u00f6zdizimini kullanabiliriz:<\/span><\/p>\n<pre style=\"background-color: #ececec; font-size: 15px;\"> <span style=\"color: #000000;\"><strong><span style=\"color: #008000;\">library<\/span> (dplyr)\n\n<span style=\"color: #008080;\">#create new data frame that repeats each row in original data frame 3 times\n<\/span>new_df &lt;- df %&gt;% slice(rep(1:n(), <span style=\"color: #3366ff;\">each<\/span> = 3))\n\n<span style=\"color: #008080;\">#view new data frame\n<\/span>new_df\n\n  team points rebound assists\n1 to 10 4 2\n2 to 10 4 2\n3 to 10 4 2\n4 B 15 8 5\n5 B 15 8 5\n6 B 15 8 5<\/strong><\/span><\/pre>\n<p> <span style=\"color: #000000;\">Orijinal veri \u00e7er\u00e7evesindeki sat\u0131rlar\u0131n her birinin \u00fc\u00e7 kez tekrarland\u0131\u011f\u0131na dikkat edin.<\/span><\/p>\n<h2> <span style=\"color: #000000;\"><strong>\u00d6rnek 2: Her sat\u0131r\u0131 farkl\u0131 say\u0131da \u00e7o\u011falt\u0131n<\/strong><\/span><\/h2>\n<p> <span style=\"color: #000000;\">R&#8217;de iki sat\u0131rl\u0131 a\u015fa\u011f\u0131daki veri \u00e7er\u00e7evesine sahip oldu\u011fumuzu varsayal\u0131m:<\/span><\/p>\n<pre style=\"background-color: #ececec; font-size: 15px;\"> <span style=\"color: #000000;\"><strong><span style=\"color: #008080;\">#create data frame\n<span style=\"color: #000000;\">df &lt;- data. <span style=\"color: #3366ff;\">frame<\/span> (team=c('A', 'B'),\n                 dots=c(10, 15),\n                 rebounds=c(4, 8),\n                 assists=c(2, 5))\n\n<span style=\"color: #008080;\">#view data frame\n<\/span>df\n\n  team points rebound assists\n1 to 10 4 2\n2 B 15 8 5\n<\/span><\/span><\/strong><\/span><\/pre>\n<p> <span style=\"color: #000000;\">\u0130lk sat\u0131r\u0131 \u00fc\u00e7 kez, ikinci sat\u0131r\u0131 be\u015f kez tekrarlamak i\u00e7in a\u015fa\u011f\u0131daki s\u00f6zdizimini kullanabiliriz:<\/span><\/p>\n<pre style=\"background-color: #ececec; font-size: 15px;\"> <span style=\"color: #000000;\"><strong><span style=\"color: #008000;\">library<\/span> (dplyr)\n\n<span style=\"color: #008080;\">#create new data frame that repeats first row 3 times and second row 5 times\n<\/span>new_df &lt;- df %&gt;% slice(rep(1:n(), <span style=\"color: #3366ff;\">times<\/span> = c(3, 5)))\n\n<span style=\"color: #008080;\">#view new data frame\n<\/span>new_df\n\n  team points rebound assists\n1 to 10 4 2\n2 to 10 4 2\n3 to 10 4 2\n4 B 15 8 5\n5 B 15 8 5\n6 B 15 8 5\n7 B 15 8 5\n8 B 15 8 5<\/strong><\/span><\/pre>\n<p> <span style=\"color: #000000;\">Orijinal veri \u00e7er\u00e7evesinin ilk sat\u0131r\u0131n\u0131n \u00fc\u00e7 kez, ikinci sat\u0131r\u0131n\u0131n ise be\u015f kez tekrarland\u0131\u011f\u0131na dikkat edin.<\/span><\/p>\n<p> <span style=\"color: #000000;\"><strong>\u0130lgili:<\/strong> <a href=\"https:\/\/statorials.org\/tr\/dplyr-dilimi\/\" target=\"_blank\" rel=\"noopener\">dplyr&#8217;da dilim () i\u015flevi nas\u0131l kullan\u0131l\u0131r?<\/a><\/span><\/p>\n<h2> <span style=\"color: #000000;\"><strong>Ek kaynaklar<\/strong><\/span><\/h2>\n<p> <span style=\"color: #000000;\">A\u015fa\u011f\u0131daki e\u011fitimlerde dplyr&#8217;de di\u011fer yayg\u0131n i\u015flemlerin nas\u0131l ger\u00e7ekle\u015ftirilece\u011fi a\u00e7\u0131klanmaktad\u0131r:<\/span><\/p>\n<p><a href=\"https:\/\/statorials.org\/tr\/dplyr-sutunlari-dizine-gore-sec\/\" target=\"_blank\" rel=\"noopener\">Dplyr kullanarak dizine g\u00f6re s\u00fctunlar nas\u0131l se\u00e7ilir<\/a><br \/> <a href=\"https:\/\/statorials.org\/tr\/dplyr-grubunun-ilk-satirini-secin\/\" target=\"_blank\" rel=\"noopener\">Dplyr kullanarak gruba g\u00f6re ilk sat\u0131r nas\u0131l se\u00e7ilir<\/a><br \/> Dplyr kullanarak birden \u00e7ok ko\u015fula g\u00f6re filtreleme nas\u0131l yap\u0131l\u0131r<br \/> <a href=\"https:\/\/statorials.org\/tr\/dplyr-dizesini-iceren-filtre-satirlari\/\" target=\"_blank\" rel=\"noopener\">Belirli bir dizeyi i\u00e7eren sat\u0131rlar\u0131 dplyr kullanarak nas\u0131l filtreleyebilirim?<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Dplyr paketindeki i\u015flevleri kullanarak R&#8217;deki bir veri \u00e7er\u00e7evesindeki sat\u0131rlar\u0131 \u00e7o\u011faltmak i\u00e7in a\u015fa\u011f\u0131daki y\u00f6ntemleri kullanabilirsiniz: Y\u00f6ntem 1: Her sat\u0131r\u0131 ayn\u0131 say\u0131da \u00e7o\u011falt\u0131n library (dplyr) #replicate each row 3 times df %&gt;% slice(rep(1:n(), each = 3)) Y\u00f6ntem 2: Her sat\u0131r\u0131 farkl\u0131 say\u0131da \u00e7o\u011falt\u0131n library (dplyr) #replicate the first row 3 times and the second row 5 times [&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-3680","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;de bir veri \u00e7er\u00e7evesindeki sat\u0131rlar nas\u0131l \u00e7o\u011falt\u0131l\u0131r<\/title>\n<meta name=\"description\" content=\"Bu e\u011fitimde, R&#039;deki bir veri \u00e7er\u00e7evesindeki sat\u0131rlar\u0131n nas\u0131l \u00e7o\u011falt\u0131laca\u011f\u0131 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\/rdeki-satirlari-cogalt\/\" \/>\n<meta property=\"og:locale\" content=\"tr_TR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"R - Statorials&#039;de bir veri \u00e7er\u00e7evesindeki sat\u0131rlar nas\u0131l \u00e7o\u011falt\u0131l\u0131r\" \/>\n<meta property=\"og:description\" content=\"Bu e\u011fitimde, R&#039;deki bir veri \u00e7er\u00e7evesindeki sat\u0131rlar\u0131n nas\u0131l \u00e7o\u011falt\u0131laca\u011f\u0131 birka\u00e7 \u00f6rnekle a\u00e7\u0131klanmaktad\u0131r.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/\" \/>\n<meta property=\"og:site_name\" content=\"Statorials\" \/>\n<meta property=\"article:published_time\" content=\"2023-07-16T04:16:30+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\/rdeki-satirlari-cogalt\/\",\"url\":\"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/\",\"name\":\"R - Statorials&#39;de bir veri \u00e7er\u00e7evesindeki sat\u0131rlar nas\u0131l \u00e7o\u011falt\u0131l\u0131r\",\"isPartOf\":{\"@id\":\"https:\/\/statorials.org\/tr\/#website\"},\"datePublished\":\"2023-07-16T04:16:30+00:00\",\"dateModified\":\"2023-07-16T04:16:30+00:00\",\"author\":{\"@id\":\"https:\/\/statorials.org\/tr\/#\/schema\/person\/365dc158a39a7c8ae256355451e3de48\"},\"description\":\"Bu e\u011fitimde, R&#39;deki bir veri \u00e7er\u00e7evesindeki sat\u0131rlar\u0131n nas\u0131l \u00e7o\u011falt\u0131laca\u011f\u0131 birka\u00e7 \u00f6rnekle a\u00e7\u0131klanmaktad\u0131r.\",\"breadcrumb\":{\"@id\":\"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/#breadcrumb\"},\"inLanguage\":\"tr\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Ev\",\"item\":\"https:\/\/statorials.org\/tr\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"R&#39;de bir veri \u00e7er\u00e7evesindeki sat\u0131rlar nas\u0131l \u00e7o\u011falt\u0131l\u0131r\"}]},{\"@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;de bir veri \u00e7er\u00e7evesindeki sat\u0131rlar nas\u0131l \u00e7o\u011falt\u0131l\u0131r","description":"Bu e\u011fitimde, R&#39;deki bir veri \u00e7er\u00e7evesindeki sat\u0131rlar\u0131n nas\u0131l \u00e7o\u011falt\u0131laca\u011f\u0131 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\/rdeki-satirlari-cogalt\/","og_locale":"tr_TR","og_type":"article","og_title":"R - Statorials&#39;de bir veri \u00e7er\u00e7evesindeki sat\u0131rlar nas\u0131l \u00e7o\u011falt\u0131l\u0131r","og_description":"Bu e\u011fitimde, R&#39;deki bir veri \u00e7er\u00e7evesindeki sat\u0131rlar\u0131n nas\u0131l \u00e7o\u011falt\u0131laca\u011f\u0131 birka\u00e7 \u00f6rnekle a\u00e7\u0131klanmaktad\u0131r.","og_url":"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/","og_site_name":"Statorials","article_published_time":"2023-07-16T04:16:30+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\/rdeki-satirlari-cogalt\/","url":"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/","name":"R - Statorials&#39;de bir veri \u00e7er\u00e7evesindeki sat\u0131rlar nas\u0131l \u00e7o\u011falt\u0131l\u0131r","isPartOf":{"@id":"https:\/\/statorials.org\/tr\/#website"},"datePublished":"2023-07-16T04:16:30+00:00","dateModified":"2023-07-16T04:16:30+00:00","author":{"@id":"https:\/\/statorials.org\/tr\/#\/schema\/person\/365dc158a39a7c8ae256355451e3de48"},"description":"Bu e\u011fitimde, R&#39;deki bir veri \u00e7er\u00e7evesindeki sat\u0131rlar\u0131n nas\u0131l \u00e7o\u011falt\u0131laca\u011f\u0131 birka\u00e7 \u00f6rnekle a\u00e7\u0131klanmaktad\u0131r.","breadcrumb":{"@id":"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/#breadcrumb"},"inLanguage":"tr","potentialAction":[{"@type":"ReadAction","target":["https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/statorials.org\/tr\/rdeki-satirlari-cogalt\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Ev","item":"https:\/\/statorials.org\/tr\/"},{"@type":"ListItem","position":2,"name":"R&#39;de bir veri \u00e7er\u00e7evesindeki sat\u0131rlar nas\u0131l \u00e7o\u011falt\u0131l\u0131r"}]},{"@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\/3680","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=3680"}],"version-history":[{"count":0,"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/posts\/3680\/revisions"}],"wp:attachment":[{"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/media?parent=3680"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/categories?post=3680"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/statorials.org\/tr\/wp-json\/wp\/v2\/tags?post=3680"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}